Action-Based Test Carving for Android Apps

Action-Based Test Carving for Android Apps
复制标题

DOI:
10.1109/icstw58534.2023.00032
复制
发表时间:
2023-04
期刊:
2023 IEEE International Conference on Software Testing, Verification and Validation Workshops (ICSTW)
影响因子:
--
通讯作者:
Alessio Gambi;Hemant Gouni;Daniel Berreiter;Vsevolod Tymofyeyev;M. Fazzini
Alessio Gambi;Hemant Gouni;Daniel Berreiter;Vsevolod Tymofyeyev;M. Fazzini
中科院分区:
其他
文献类型:
--
作者:
Alessio Gambi;Hemant Gouni;Daniel Berreiter;Vsevolod Tymofyeyev;M. Fazzini

文献摘要

相似文献

Android应用程序的测试套件应利用不同类型的测试,包括端到端测试,这些测试验证用户流动,并提供针对调试的重点执行的单位测试。 device are not really focused, as they use the full implementation of the Android framework. Moreover, they are fairly slow to execute, requiring the Android system as the runtime. Unit tests that run on the JVM, instead, are more focused and run more efficiently but require developers to suitably handle the coupling between the app under test and the Android framework. To help developers in creating focused unit tests that run on the JVM, we propose a novel technique called根据测试雕刻的想法(i)在Android设备上的端到端测试过程中,(ii)确定了测试的焦点方法,(iii)雕刻了这些方法的必要先决条件,(IV)可以使用Android Framework进行15次测试。 - 五个应用程序的末端测试,并观察到工匠可以生成涵盖端到端测试行使的大部分代码的单位测试(即平均45%的起始声明覆盖范围),并在几分钟内进行。
The test suites of an Android app should take advantage of different types of tests including end-to-end tests, which validate user flows, and unit tests, which provide focused executions for debugging. App developers have two main options when creating unit tests: create unit tests that run on a device (either physical or emulated) or create unit tests that run on a development machine’s Java Virtual Machine (JVM). Unit tests that run on a device are not really focused, as they use the full implementation of the Android framework. Moreover, they are fairly slow to execute, requiring the Android system as the runtime. Unit tests that run on the JVM, instead, are more focused and run more efficiently but require developers to suitably handle the coupling between the app under test and the Android framework. To help developers in creating focused unit tests that run on the JVM, we propose a novel technique called ARTISAN based on the idea of test carving. The technique (i) traces the app execution during end-to-end testing on Android devices, (ii) identifies focal methods to test, (iii) carves the necessary preconditions for testing those methods, (iv) creates suitable test doubles for the Android framework, and (v) synthesizes executable unit tests that can run on the JVM. We evaluated ARTISAN using 152 end-to-end tests from five apps and observed that ARTISAN can generate unit tests that cover a significant portion of the code exercised by the end-to-end tests (i.e., 45% of the starting statement coverage on average) and does so in a few minutes.