HapTest: The Dynamic Analysis Framework for OpenHarmony

Farong Liu, Mingyi Zhou, Yakun Zhang, Ting Su, Bo Sun, Jacques Klein, Xiang Gao, Li Li

Research output: Chapter in Book/Report/Conference proceedingConference contributionpeer-review

Abstract

ArkTS is a new programming language dedicated to developing applications (apps) for the emerging OpenHarmony mobile operating system. Like other programs, apps developed with ArkTS suffer from bugs, leading to, e.g., crashes, or performance and security issues. Our community usually uses dynamic analysis to analyze the app’s behavior and detect bugs. Unfortunately, a framework tailored for OpenHarmony apps dynamic analysis is not yet available for the developer community. To bridge this gap, we propose a new dynamic analysis framework named HapTest, which has been specifically designed to cope with OpenHarmony apps’ original features. We make HapTest publicly available as an open-source project. Our HapTest has several fundamental dynamic analysis features (e.g., PTG, DataHub, etc.) that are ready to be reused by developers, and further customized to enable specific dynamic analysis, for instance, to detect malware or performance issues. Experiment results show that our HapTest achieves both high analysis coverage and high effectiveness. In addition, our HapTest is evaluated on the top 20 popular commercial apps from the OpenHarmony app market, each with at least millions of downloads. Our testing method revealed 26 previously unreported crashes in 11 out of the 20 applications, which demonstrates the practicality of HapTest.

Original languageEnglish
Title of host publicationFSE Companion 2025 - Companion Proceedings of the 33rd ACM International Conference on the Foundations of Software Engineering
EditorsJingyue Li
PublisherAssociation for Computing Machinery
Pages422-431
Number of pages10
ISBN (Electronic)9798400712760
DOIs
StatePublished - 28 Jul 2025
Event33rd ACM International Conference on the Foundations of Software Engineering, FSE Companion 2025 - Trondheim, Norway
Duration: 23 Jun 202527 Jun 2025

Publication series

NameProceedings of the ACM SIGSOFT Symposium on the Foundations of Software Engineering
ISSN (Print)1539-7521

Conference

Conference33rd ACM International Conference on the Foundations of Software Engineering, FSE Companion 2025
Country/TerritoryNorway
CityTrondheim
Period23/06/2527/06/25

Keywords

  • ArkTS
  • Automated Testing
  • Dynamic Analysis
  • GUI Testing
  • Mobile Application Testing
  • OpenHarmony

Fingerprint

Dive into the research topics of 'HapTest: The Dynamic Analysis Framework for OpenHarmony'. Together they form a unique fingerprint.

Cite this