Build unit tests in separate pipeline job
The current pipeline is set up to build all targets in the
build:main build with
Release flags (with optimization). this includes all unit tests which might become more in the future and clutter the finished Docker application.
We should start distinguishing between
system tests: tests on the final application, i.e., the
- unit tests: tests that run special executables which only serve this purpose
- Further split the
buildstage by creating a new job
build:unit-tests: Compile all (unit) test executables.
- Add job
test:unit-teststo the testing stage: Run all system test executables here.
- Add custom target
unit_testfor running all system tests. This requires a naming convention for system tests: All system test targets must begin with
test. They will be collected into the custom target using a regex match.
How to test the implementation?
New pipeline succeeds.
@sospinar, what do you think?