Festo-se / cyclonedx-editor-validator

Tool for creating, modifying and validating CycloneDX SBOMs.
https://festo-se.github.io/cyclonedx-editor-validator/
GNU General Public License v3.0
18 stars 4 forks source link

tests: Add integration tests #157

Closed mmarseu closed 1 month ago

mmarseu commented 4 months ago

This PR primarily adds integration testing to test the tool's functionality from a "outside" perspective. These tests invoke the main function directly so they are about as abstract as can be.

The goal is to ensure that the kind of internal redesign as is planned for #7 will not create any regressions. Existing unit tests are not fit for this because they are so tightly coupled to the design that they, too, will have to be reworked, creating the risk of regressions inside the tests.

Tests for the following commands are implemented:

Not to be implemented:

A few minor additional changes

github-actions[bot] commented 1 month ago

Coverage

Coverage Report •
FileStmtsMissCoverMissing
__main__.py3231695%217–218, 235, 245, 670, 713, 758, 763, 767, 789, 803, 807, 811, 813, 822, 832
error.py230100% 
log.py55198%36
set.py1832089%56–59, 78–86, 88–89, 91–94, 105
validator
   customreports.py85989%46–47, 54–57, 97, 149–150
   validate.py96396%118, 134, 169
TOTAL16887195% 

Tests Skipped Failures Errors Time
349 2 :zzz: 0 :x: 0 :fire: 10.586s :stopwatch: