Comprehending Test Code: An Empirical Study

Chak Shun Yu, Christoph Treude, Maurício Aniche

Research output: Chapter in Book/Conference proceedings/Edited volumeConference contributionScientificpeer-review

46 Downloads (Pure)

Abstract

Developers spend a large portion of their time and effort on comprehending source code. While many studies have investigated how developers approach these comprehension tasks and what factors influence their success, less is known about how developers comprehend test code specifically, despite the undisputed importance of testing. In this paper, we report on the results of an empirical study with 44 developers to understand which factors influence developers when comprehending Java test code. We measured three dependent variables: the total time spent reading a test suite, the ability to identify the overall purpose of a test suite, and the ability to produce additional test cases to extend a test suite. The main findings of our study, with several implications for future research and practitioners, are that (i) prior knowledge of the software project decreases the total reading time, (ii) experience with Java affects the proportion of time spent on the Arrange and Assert sections of test cases, (iii) experience with Java and prior knowledge of the software project positively influence the ability to produce additional test cases of certain categories, and (iv) experience with automated tests is an influential factor towards understanding and extending an automated test suite.
Original languageEnglish
Title of host publicationProceedings of the 35th IEEE International Conference on Software Maintenance and Evolution
PublisherIEEE
Pages501-512
ISBN (Electronic)978-1-7281-3094-1
ISBN (Print)978-1-7281-3095-8
DOIs
Publication statusPublished - 2019
Event2019 IEEE International Conference on Software Maintenance and Evolution, ICSME 2019 - Cleveland, United States
Duration: 30 Sep 20194 Oct 2019
https://icsme2019.github.io

Conference

Conference2019 IEEE International Conference on Software Maintenance and Evolution, ICSME 2019
Abbreviated titleICSME 2019
CountryUnited States
CityCleveland
Period30/09/194/10/19
Internet address

Keywords

  • software engineering
  • test engineering
  • program comprehension
  • test code comprehension
  • empirical software engineering

Fingerprint Dive into the research topics of 'Comprehending Test Code: An Empirical Study'. Together they form a unique fingerprint.

Cite this