一句话:提出 ACETON,用深度学习自动构建 Android 能耗测试预言,判定是否存在能耗缺陷及其类型。
能耗逐渐成为移动应用的重要质量属性,但当前缺乏有效的能耗测试工具,尤其测试预言(oracle)问题尚未解决。现有研究主要关注测试输入生成。本文提出 ACETON,首个面向移动应用能耗行为测试的预言自动构建方法。ACETON 采用深度学习构建预言,不仅判断一次测试执行是否暴露能耗缺陷,还能识别缺陷类型。通过选取可在任意应用和移动设备上监控的特征,该方法构建的预言具有较高可复用性。实验表明,ACETON 生成的预言整体精确率和召回率均达到 99%,并且平均仅需 37 毫秒即可检测出能耗缺陷,兼具高准确性与高效率。
Energy efficiency is an increasingly important quality attribute for software, particularly for mobile apps. Just like any other software attribute, energy behavior of mobile apps should be properly tested prior to their release. However, mobile apps are riddled with energy defects, as currently there is a lack of proper energy testing tools. Indeed, energy testing is a fledgling area of research and recent advances have mainly focused on test input generation. This paper presents ACETON, the first approach aimed at solving the oracle problem for testing the energy behavior of mobile apps. ACETON employs Deep Learning to automatically construct an oracle that not only determines whether a test execution reveals an energy defect, but also the type of energy defect. By carefully selecting features that can be monitored on any app and mobile device, we are assured the oracle constructed using ACETON is highly reusable. Our experiments show that the oracle produced by ACETON is both highly accurate, achieving an overall precision and recall of 99%, and efficient, detecting the existence of energy defects in only 37 milliseconds on average.