Test Analysis: Searching for Faults in Tests (N)
Test Analysis: Searching for Faults in Tests (N)
复制标题
测试分析:寻找测试中的故障(N)
DOI:
--
复制
发表时间:
2015
期刊:
影响因子:
--
通讯作者:
Sebastian G. Elbaum
中科院分区:
文献类型:
--
作者:
M. Waterloo;Suzette Person;Sebastian G. Elbaum
Tests are increasingly specified as programs. Expressing tests as code is advantageous in that developers are comfortable writing and running code, and tests can be automated and reused as the software evolves. Tests expressed as code, however, can also contain faults. Some test faults are similar to those found in application code, while others are more subtle, caused by incorrect implementation of testing concepts and processes. These faults may cause a test to fail when it should not, or allow program faults to go undetected. In this work we explore whether lightweight static analyses can be cost-effective in pinpointing patterns associated with faults tests. Our exploration includes a categorization and explanation of test patterns, and their application to 12 open source projects that include over 40K tests. We found that several patterns, detectable through simple and efficient static analyses of just the test code, can detect faults with a low false positive rate, while other patterns would require a more sophisticated and extensive code analysis to be useful.