Hi all, on January 26th I will be speaking about Advanced Code Coverage with Jenkins, GitHub and API Mocks at 90DaysOfDevOps. This is a new edition of my talk adapted to Coverage Plugin and also providing tips on building Gradle/Maven projects, and using Testcontainers and WireMock in Integration tests to improve test coverage. I am starting this thread as a Q&A endpoint for the presentation and video that will go live on January 21st
Feel free to ask any questions here! I am also happy to share the slides in advance with all interested folks. And kudos to @uhafner, @timja, Kezhi Xiong, @Shenyu Zheng, Florian Orendi and all contributors!
- Slides: (premiers Jan 26): https://speakerdeck.com/onenashev/advanced-code-coverage-with-jenkins-github-and-api-mocking
- Video: https://www.youtube.com/watch?v=ZBaQ71CI_lI
Full abstract:
In 2015-2018, I talked about how to use the Jenkins Pipeline and custom libraries to do advanced integration tests and analyze code coverage. Coverage plugins were rather weak, and one needed some scripts and hacks to make it work, and to DIY for distributed testing. In 2021 the situation has changed significantly thanks to the Coverage and Checks API plugins. Distributed integration testing also became easier thanks to better coverage collectors and integrations with API mocking tools. So, good time to be alive… and use Jenkins!
We will talk about how modern Jenkins allows you to improve and analyze code coverage. We will talk about unit and integration testing with WireMock, the new Coverage Plugin, support for standard formats (Cobertura, JaCoCo, gcov, JUnit, etc.), parallelization for heavy integration tests and API mocking, and integration with GitHub Checks API. How can you analyze code coverage in Jenkins and when do you need to create your own libraries? And what’s the fuzz about Testcontainers and WireMock for integration testing?