Test Runner: Running the tests and seeing the coverage

Now for the final stage, running the tests and seeing the coverage.

Running the tests is done via the test_runner pipeline, in this pipeline you'll see some of the most popular testing frameworks and how it's integrated with Sealights.

We're not going to dive into every testing framework. If you want to know how to integrate Sealights test runner agent on a specific testing framework check the relevant pipeline stage.

You can find the pipeline in the repository under jenkins/jenkinsfiles/test_runner.groovy

When running the test_runner you will be redirected to the "stage view", there you'll see the pipeline's stages.

pipeline's stages

When starting a test stage you should be able to see the new integration build in the Sealight's website dashboard.

Integration build updated

The difference between a normal build and an integration build is that the normal build is one scanning one app and you run the tests on it. The integration build consists of multiple apps that share the same lab_id, when running tests using a lab_id which is given to multiple Sealights agents who are currently online (apps running with Sealights) it automatically understands you're trying to test an app of multiple microservices.

When clicking on the coverage (The 0% in the picture) you will be redirected to the stage view page, there you should be able to see all the microservice that were deployed and are currently running using the same lab_id that we used to run the tests

All the microservices that are running that share the same lab_id

After some time you should start seeing the (in progress) under the integration build's coverage indicating that there is a test in progress

Integration build under test

When clicking the bar (for example public-BTQ the build name) it will reveal all the test stages including those in progress.

Revealing test stages

After a while you should be able to see the coverage start increasing until reaching 68% in this example.

--------------- add percentage without in progress /// going to show percentages, need them to be stable

Congrats, you can now see the tests coverage of the code, the next step is getting modified coverage. Meaning getting how much of the code changes are covered by the tests. There is a way to do it easily and we'll show you how next.

Or if you're not currently interested in that we suggest we give you a tour in our website to show you very useful features we offer that will help you understand your code and/or debug.

Tour through Sealights website

Last updated