From: Alexander Popov Date: Fri, 10 Mar 2023 20:22:47 +0000 (+0300) Subject: Create a separate CI workflow for unit-tests X-Git-Tag: v0.6.6~219 X-Git-Url: https://jxself.org/git/?a=commitdiff_plain;h=f028b42b62cb7e911e9b6849fd182997e7b3def1;p=kconfig-hardened-check.git Create a separate CI workflow for unit-tests --- diff --git a/.github/workflows/engine_unit-test.yml b/.github/workflows/engine_unit-test.yml new file mode 100644 index 0000000..92591c6 --- /dev/null +++ b/.github/workflows/engine_unit-test.yml @@ -0,0 +1,33 @@ +name: engine unit-test + +on: + push: + branches: [ master ] + pull_request: + branches: [ master ] + +jobs: + engine_unit-test: + + runs-on: ubuntu-latest + + strategy: + max-parallel: 1 + fail-fast: false + matrix: + python-version: ['3.11'] + + steps: + + - name: Set up Python ${{ matrix.python-version }} + uses: actions/setup-python@v4 + with: + python-version: ${{ matrix.python-version }} + + - name: Get source code for collecting coverage + uses: actions/checkout@v3 + + - name: Run unit-tests and collect coverage + run: | + coverage run --include=kconfig_hardened_check/engine.py,kconfig_hardened_check/test_engine.py -m unittest -v + coverage xml -i -o coverage_unittest.xml diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index eb1a8dd..1f2306e 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -7,7 +7,7 @@ on: branches: [ master ] jobs: - check_all_configs: + functional_test: runs-on: ubuntu-latest @@ -165,13 +165,3 @@ jobs: name: codecov-umbrella fail_ci_if_error: true verbose: true - - - name: Erase coverage - run: | - coverage erase - rm ./coverage.xml - - - name: Run unit-tests and collect coverage - run: | - coverage run --include=kconfig_hardened_check/engine.py,kconfig_hardened_check/test_engine.py -m unittest -v - coverage xml -i -o coverage_unittest.xml