LELANTE: LEveraging LLM for Automated ANdroid TEsting
Shamit Fatin, Mehbubul Hasan Al-Quvi, Haz Sameen Shahgir, Sukarna Barua, Anindya Iqbal, Sadia Sharmin, Md. Mostofa Akbar, Kallol Kumar Pal, A. Asif Al Rashid
TL;DR
LELANTE addresses the challenge of testing Android apps without manually scripting interactions by using large language models to interpret natural language test case descriptions and autonomously drive GUI actions. It introduces a GUI refinement pipeline to produce a structured, noise-reduced screen representation, and a structured, chain-of-thought prompting strategy that enables iterative action generation and error recovery through backtracking. The framework leverages Appium for on-device execution and employs distillation via LoRA to reduce computational cost, achieving a 73% test execution success rate and 78% error recovery across 390 test cases from 10 apps. The work demonstrates the practical potential of LLM-driven automation for scalable mobile testing, while identifying limitations such as final-state verification and backtracking efficiency, and outlining directions for future improvements. Overall, LELANTE bridges natural-language test descriptions and automated, adaptable test execution, enabling scalable testing workflows with reduced manual scripting effort.
Abstract
Given natural language test case description for an Android application, existing testing approaches require developers to manually write scripts using tools such as Appium and Espresso to execute the corresponding test case. This process is labor-intensive and demands significant effort to maintain as UI interfaces evolve throughout development. In this work, we introduce LELANTE, a novel framework that utilizes large language models (LLMs) to automate test case execution without requiring pre-written scripts. LELANTE interprets natural language test case descriptions, iteratively generate action plans, and perform the actions directly on the Android screen using its GUI. LELANTE employs a screen refinement process to enhance LLM interpretability, constructs a structured prompt for LLMs, and implements an action generation mechanism based on chain-of-thought reasoning of LLMs. To further reduce computational cost and enhance scalability, LELANTE utilizes model distillation using a foundational LLM. In experiments across 390 test cases spanning 10 popular Android applications, LELANTE achieved a 73% test execution success rate. Our results demonstrate that LLMs can effectively bridge the gap between natural language test case description and automated execution, making mobile testing more scalable and adaptable.
