A reinforcement learning-based approach to testing GUI of moblie applications
Publication Date
3-1-2024
Document Type
Article
Publication Title
World Wide Web
Volume
27
Issue
2
DOI
10.1007/s11280-024-01252-9
Abstract
With the popularity of mobile devices, the software market of mobile applications has been booming in recent years. Android applications occupy a vast market share. However, the applications inevitably contain defects. Defects may affect the user experience and even cause severe economic losses. This paper proposes ATAC and ATPPO, which apply reinforcement learning to Android GUI testing to mitigate the state explosion problem. The article designs a new reward function and a new state representation. It also constructs two GUI testing models (ATAC and ATPPO) based on A2C and PPO algorithms to save memory space and accelerate training speed. Empirical studies on twenty open-source applications from GitHub demonstrate that: (1) ATAC performs best in 16 of 20 apps in code coverage and defects more exceptions; (2) ATPPO can get higher code coverage in 15 of 20 apps and defects more exceptions; (3) Compared with state-of-art tools Monkey and ARES, ATAC, and ATPPO shows higher code coverage and detects more errors. ATAC and ATPPO can not only cover more code coverage but also can effectively detect more exceptions. This paper also introduces Finite-State Machine into the reinforcement learning framework to avoid falling into the local optimal state, which provides high-level guidance for further improving the test efficiency.
Keywords
Advantage actor critic, Proximal policy optimization, Finite-state machine, GUI testing, Reinforcement learning
Department
Computer Engineering
Recommended Citation
Chuanqi Tao, Fengyu Wang, Yuemeng Gao, Hongjing Guo, and Jerry Gao. "A reinforcement learning-based approach to testing GUI of moblie applications" World Wide Web (2024). https://doi.org/10.1007/s11280-024-01252-9