首页> 外文期刊>ACM transactions on software engineering and methodology >Amplifying Tests to Validate Exception Handling Code: An Extended Study in the Mobile Application Domain
【24h】

Amplifying Tests to Validate Exception Handling Code: An Extended Study in the Mobile Application Domain

机译:验证异常处理代码的放大测试:在移动应用领域的扩展研究

获取原文
获取原文并翻译 | 示例

摘要

Validating code handling exceptional behavior is difficult, particularly when dealing with external resources that may be noisy and unreliable, as it requires (1) systematic exploration of the space of exceptions that may Be thrown by the external resources, and (2) setup of the context to trigger specific patterns of exceptions. In this work, we first present a study quantifying the magnitude of the problem by inspecting the bug repositories of a set of popular applications in the increasingly relevant domain of Android mobile applications. The study revealed that 22% of the confirmed and fixed bugs have to do with poor exceptional handling code, and half of those correspond to interactions with external resources. We then present an approach that addresses this challenge by performing an systematic amplification of the program space explored by a test by manipulating the behavior of external resources. Each amplification attempts to expose a program's exception handling constructs to new behavior by mocking an external resource so that it returns normally or throws an exception following a predefined set of patterns. Our assessment of the approach indicates that it can be fully automated, is powerful enough to detect 67% of the faults reported in the bug reports of this kind, and is precise enough that 78% of the detected anomalies are fixed, and it has a great potential to assist developers.
机译:验证代码处理异常行为非常困难,尤其是在处理可能嘈杂且不可靠的外部资源时,因为这需要(1)系统地研究可能由外部资源引发的异常空间,以及(2)设置上下文触发特定的异常模式。在这项工作中,我们首先提出一项研究,通过检查越来越紧密相关的Android移动应用程序领域中一组流行应用程序的错误存储库来量化问题的严重程度。该研究表明,已确认和已修复的错误中有22%与不良的异常处理代码有关,其中一半与与外部资源的交互相对应。然后,我们通过处理外部资源的行为,通过对测试所探索的程序空间进行系统的放大,提出了一种解决这一挑战的方法。每次放大都通过模拟外部资源来尝试使程序的异常处理构造暴露于新行为,以使其正常返回或按照一组预定义的模式引发异常。我们对该方法的评估表明,该方法可以完全自动化,功能强大,足以检测此类错误报告中报告的67%的错误,并且足够精确,可以修复78%的检测到的异常,并且具有协助开发人员的巨大潜力。

著录项

相似文献

  • 外文文献
  • 中文文献
  • 专利
获取原文

客服邮箱:kefu@zhangqiaokeyan.com

京公网安备:11010802029741号 ICP备案号:京ICP备15016152号-6 六维联合信息科技 (北京) 有限公司©版权所有
  • 客服微信

  • 服务号