< Back to previous page
A novel approach for detecting type-IV clones in test code
Book Contribution - Book Abstract Conference Contribution
The typical structure of unit test code (setup stimulate - verify - teardown) gives rise to duplicated test logic. Researchers have demonstrated the widespread use of syntactic clones in test code, yet if duplicated test code is indeed a problem, then semantic clones may be an issue as well. However, while detecting syntactic similarities can be done relatively easy, semantic similarities are more difficult to find. In this paper we present a novel way of detecting semantic clones by exploiting the unique features present in test code. We demonstrate on the Apache Commons Math Library's test suite that our approach can detect 259 semantic clones, of which only 54 were also detected by NiCad. This confirms that it is both feasible and worthwhile to investigate semantic clones in test code.
Book: 13th IEEE International Workshop on Software Clones (IWSC), FEB 24, 2019, Hangzhou, PEOPLES R CHINA
Pages: 8 - 12
Authors from:Higher Education