Learning-based Widget Matching for Migrating GUI Test Cases
Yakun Zhang, Wenjie Zhang, Dezhi Ran, Qihao Zhu, Chengfeng Dou, Dan Hao, Tao Xie, Lu Zhang
Abstract
GUI test case migration is to migrate GUI test cases from a source app to a target app. The key of test case migration is widget matching. Recently, researchers have proposed various approaches by formulating widget matching as a matching task. However, since these matching approaches depend on static word embeddings without using contextual information to represent widgets and manually formulated matching functions, there are main limitations of these matching approaches when handling complex matching relations in apps. To address the limitations, we propose the first learning-based widget matching approach named TEMdroid (TEst Migration) for test case migration. Unlike the existing approaches, TEMdroid uses BERT to capture contextual information and learns a matching model to match widgets. Additionally, to balance the significant imbalance between positive and negative samples in apps, we design a two-stage training strategy where we first train a hard-negative sample miner to mine hard-negative samples, and further train a matching model using positive samples and mined hard-negative samples. Our evaluation on 34 apps shows that TEM-droid is effective in event matching (i.e., widget matching and target event synthesis) and test case migration. For event matching, TEM-droid's Top1 accuracy is 76%, improving over 17% compared to baselines. For test case migration, TEMdroid's F1 score is 89%, also 7% improvement compared to the baseline approach.
Ask about this paper
Your agent reads all of it.
Lune indexed this paper to the last equation, along with the top-tier papers that cite it. Ask a question and the answer quotes them.
Your agent calls
Luneget_paper_fulltext
Free to start. No credit card required.
Terminal
Install the CLIlune papers fulltext 56047279-052d-44cf-8829-8550d8a8090eCited by top-tier papers14
- Can Large Language Models Write Parallel Code?Daniel Nichols, Joshua Hoke Davis, Zhaojun Xie, Arjun Rajaram et al.HPDC 2024 · 30 citations
- CodeSense: a Real-World Benchmark and Dataset for Code Semantic ReasoningMonoshi Kumar Roy, Simin Chen, Benjamin Steenhoek, Jinjun Peng et al.ICLR 2026 · 18 citations
- OctoBench: Benchmarking Scaffold-Aware Instruction Following in Repository-Grounded Agentic CodingDeming Ding, Shichun Liu, Enhui Yang, Jiahang Lin et al.ACL 2026 · 10 citations
- Can Language Models Replace Programmers for Coding? REPOCOD Says 'Not Yet'Shanchao Liang, Nan Jiang, Yiran Hu, Lin TanACL 2025 · 9 citations
- GUIPilot: A Consistency-Based Mobile GUI Testing Approach for Detecting Application-Specific BugsRuofan Liu, Xiwen Teoh, Yun Lin, Guanjie Chen et al.ISSTA 2025 · 5 citations
Builds on6
- Language Models are Few-Shot LearnersTom B. Brown, Benjamin Mann, Nick Ryder, Melanie Subbiah et al.NeurIPS 2020 · 64,255 citations
- The Curious Case of Neural Text DegenerationAri Holtzman, Jan Buys, Li Du, Maxwell Forbes et al.ICLR 2020 · 4,112 citations
- WizardCoder: Empowering Code Large Language Models with Evol-InstructZiyang Luo, Can Xu, Pu Zhao, Qingfeng Sun et al.ICLR 2024 · 945 citations
- DS-1000: A Natural and Reliable Benchmark for Data Science Code GenerationYuhang Lai, Chengxi Li, Yiming Wang, Tianyi Zhang et al.ICML 2023 · 504 citations
- InCoder: A Generative Model for Code Infilling and SynthesisDaniel Fried, Armen Aghajanyan, Jessy Lin, Sida Wang et al.ICLR 2023 · 140 citations
Related papers
- Intention-Based GUI Test Migration for Mobile Apps using Large Language ModelsShaoheng Cao, Minxue Pan, Yuanhong Lan, Xuandong LiISSTA 2025
- Synthesis-Based Enhancement for GUI Test Case MigrationYakun Zhang, Qihao Zhu, Jiwei Yan, Chen Liu et al.ISSTA 2024 · 3 citations
- Semantic matching of GUI events for test reuse: are we there yet?Leonardo Mariani, Ali Mohebbi, Mauro Pezzè, Valerio TerragniISSTA 2021 · 34 citations
- Vision-Based Widget Mapping for Test Migration Across Mobile Platforms: Are We There Yet?Ruihua Ji, Tingwei Zhu, Xiaoqing Zhu, Chunyang Chen et al.ASE 2023 · 2 citations
- Characterizing and Repairing Obsolete Android GUI Tests under UI EvolutionShiwen Song, Yiheng Xiong, Wenbo Guo, Manqi Sun et al.ISSTA 2026
