Unveiling the Relationship Between Continuous Integration and Code Coverage
Continuous integration (CI) is a software engineering practice that advocates the frequent integration of software through an automated build process. Existing research has explored the benefits of CI, such as detecting errors earlier in the software life-cycle. Although CI places a heavy focus on automated tests, it is still not clear whether CI is associated with better code coverage, which could be a major benefit of using CI. To investigate whether CI is associated with an improvement in code coverage, our work compares 30 projects that adopted CI (CI projects) and 30 projects that have never adopted CI (NOCI projects) to investigate the relationship between the evolution of code coverage and the adoption of CI. We observe that CI projects have more rising code coverage trends (50%) when compared to NOCI projects (10%). Additionally, maintaining trends differ between CI and NOCI projects; CI projects tend to stabilize their code coverage at a higher coverage value when compared to NOCI projects. We study the types of code changes that affect the coverage levels. We identify that projects that adopted CI substantially increased the number of code changes that rised code coverage in the projects. Finally, our work reveals a positive association between CI and better code coverage.