当前位置: X-MOL 学术Software Qual. J. › 论文详情
Our official English website, www.x-mol.net, welcomes your feedback! (Note: you will need to create a separate account there.)
Sentinel: generating GUI tests for sensor leaks in Android and Android wear apps
Software Quality Journal ( IF 1.7 ) Pub Date : 2019-12-12 , DOI: 10.1007/s11219-019-09484-z
Haowei Wu , Hailong Zhang , Yan Wang , Atanas Rountev

Due to the widespread use of Android devices and apps, it is important to develop tools and techniques to improve app quality and performance. Our work focuses on a problem related to hardware sensors on Android devices: the failure to disable unneeded sensors, which leads to sensor leaks and thus battery drain. We propose the Sentinel testing tool to uncover such leaks. The tool performs static analysis of app code and produces a model which maps GUI events to callback methods that affect sensor behavior. Edges in the model are labeled with symbols representing the acquiring/releasing of sensors and the opening/closing of UI windows. The model is traversed to identify paths that are likely to exhibit sensor leaks during run-time execution based on two context-free languages over the symbol alphabet. The reported paths are then used to generate test cases. The execution of each test case tracks the run-time behavior of sensors and reports observed leaks. This approach has been applied to both open-sourced and closed-sourced regular Android applications as well as watch faces for Android Wear smartwatches. Our experimental results indicate that Sentinel effectively detects sensor leaks, while focusing the testing efforts on a very small subset of possible GUI event sequences.

中文翻译:

Sentinel:为 Android 和 Android Wear 应用程序中的传感器泄漏生成 GUI 测试

由于 Android 设备和应用程序的广泛使用,开发工具和技术以提高应用程序质量和性能非常重要。我们的工作侧重于与 Android 设备上的硬件传感器相关的问题:无法禁用不需要的传感器,这会导致传感器泄漏,从而导致电池耗尽。我们建议使用 Sentinel 测试工具来发现此类泄漏。该工具执行应用程序代码的静态分析并生成一个模型,该模型将 GUI 事件映射到影响传感器行为的回调方法。模型中的边缘用符号标记,代表传感器的获取/释放和 UI 窗口的打开/关闭。基于符号字母表上的两种上下文无关语言,遍历模型以识别在运行时执行期间可能出现传感器泄漏的路径。然后使用报告的路径生成测试用例。每个测试用例的执行都会跟踪传感器的运行时行为并报告观察到的泄漏。这种方法已应用于开源和闭源的常规 Android 应用程序以及 Android Wear 智能手表的表盘。我们的实验结果表明 Sentinel 有效地检测了传感器泄漏,同时将测试工作集中在可能的 GUI 事件序列的一个非常小的子集上。
更新日期:2019-12-12
down
wechat
bug