首页> 外文会议>IEEE/ACM International Conference on Software Engineering >Domain-Specific Fixes for Flaky Tests with Wrong Assumptions on Underdetermined Specifications
【24h】

Domain-Specific Fixes for Flaky Tests with Wrong Assumptions on Underdetermined Specifications

机译:域特定修复用于不可确定的规格的错误假设错误的假设

获取原文

摘要

Library developers can provide classes and methods with underdetermined specifications that allow flexibility in future implementations. Library users may write code that relies on a specific implementation rather than on the specification, e.g., assuming mistakenly that the order of elements cannot change in the future. Prior work proposed the NonDex approach that detects such wrong assumptions. We present a novel approach, called DexFix, to repair wrong assumptions on underdetermined specifications in an automated way. We run the NonDex tool on 200 open-source Java projects and detect 275 tests that fail due to wrong assumptions. The majority of failures are from iterating over HashMap/HashSet collections and the getDeclaredFields method. We provide several new repair strategies that can fix these violations in both the test code and the main code. DexFix proposes fixes for 119 tests from the detected 275 tests. We have already reported fixes for 102 tests as GitHub pull requests: 74 have been merged, with only 5 rejected, and the remaining pending.
机译:图书馆开发人员可以提供具有未来实施规范的规格的类和方法,以便在未来的实现中灵活。图书馆用户可以编写依赖于特定实现的代码,而不是在规范中,例如,假设要误认为元素的顺序在将来无法改变。事先工作提出了检测这种错误假设的非新的方法。我们提出了一种称为DEXFIX的新方法,以自动化方式修复未被该规格的错误假设。我们在200个开源Java项目上运行Nondex工具,并检测由于错误的假设而失败的275个测试。大多数失败都来自迭代HashMap / Hashset集合和GetDeclaredFields方法。我们提供了几种新的修复策略,可以在测试代码和主代码中解决这些违规行为。 Dexfix提出了从检测到的275测试中的119个测试修复。我们已经报告了102个测试的修复,因为GitHub拉出请求:74已被合并,只有5个被拒绝,并且剩下的待处理。

著录项

相似文献

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

客服邮箱:kefu@zhangqiaokeyan.com

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

  • 服务号