Disposable Testing: Avoiding Maintenance of Generated Unit Tests by Throwing Them Away

S. Shamshiri, J. Campos, G. Fraser, P. McMinn
International Conference on Software Engineering (ICSE), 2017

Abstract

Developers write unit tests together with program code, and then maintain these tests as the program evolves. Since writing good tests can be difficult and tedious, unit tests can also be generated automatically. However, maintaining these tests (e.g., when APIs change, or, when tests represent outdated and changed behavior), is still a manual task. Because automatically generated tests may have no clear purpose other than covering code, maintaining them may be more difficult than maintaining manually written tests. Could this maintenance be avoided by simply generating new tests after each change, and disposing the old ones? We propose disposable testing: Tests are generated to reveal any behavioral differences caused by a code change, and are thrown away once the developer confirms whether these changes were intended or not. However, this idea raises several research challenges: First, are standard automated test generation techniques good enough to produce tests that may be relied upon to reveal changes as effectively as an incrementally built regression test suite? Second, does disposable testing reduce the overall effort, or would developers need to inspect more generated tests compared to just maintaining existing ones?

Bibtex

@inproceedings{Shamshiri:2017,
  author = {Shamshiri, Sina and Campos, Jos{\'e} and Fraser, Gordon and McMinn, Phil},
  title = {Disposable Testing: Avoiding Maintenance of Generated Unit Tests by Throwing Them Away},
  booktitle = {Proceedings of the 39th ACM/IEEE International Conference on Software Engineering},
  series = {ICSE '17},
  year = {2017},
  isbn = {},
  location = {Buenos Aires, Argentina},
  pages = {},
  numpages = {3},
  url = {},
  doi = {},
  acmid = {},
  publisher = {},
  address = {},
  keywords = {},
}