diff --git a/.github/workflows/build-pipeline.yml b/.github/workflows/build-pipeline.yml index 54f3ccfb..a40a08e5 100644 --- a/.github/workflows/build-pipeline.yml +++ b/.github/workflows/build-pipeline.yml @@ -43,116 +43,3 @@ jobs: with: name: pyhanko-dist path: dist/ - pytest-coverage: - runs-on: ubuntu-latest - needs: build - strategy: - matrix: - python-version: ["3.7", "3.8", "3.9", "3.10", "3.11"] - steps: - - uses: actions/checkout@v3 - - name: Set up Python ${{ matrix.python-version }} - uses: actions/setup-python@v4 - with: - python-version: ${{ matrix.python-version }} - - name: Download dist artifacts - uses: actions/download-artifact@v3 - with: - name: pyhanko-dist - path: dist/ - - uses: ./.github/actions/test-job-setup - - name: Test with pytest - run: python -m pytest --cov=./ --cov-report=xml:python-${{ matrix.python-version }}-coverage.xml - env: - PKCS11_TEST_MODULE: ${{ env.SOFTHSM2_MODULE_PATH }} - - name: Stash coverage report - uses: actions/upload-artifact@v3 - with: - name: coverage - path: "*-coverage.xml" - live-integration-tests: - runs-on: ubuntu-latest - needs: build - strategy: - matrix: - python-version: ["3.7", "3.8", "3.9", "3.10", "3.11"] - steps: - - uses: actions/checkout@v3 - - name: Set up Python ${{ matrix.python-version }} - uses: actions/setup-python@v4 - with: - python-version: ${{ matrix.python-version }} - - name: Download dist artifacts - uses: actions/download-artifact@v3 - with: - name: pyhanko-dist - path: dist/ - - uses: ./.github/actions/test-job-setup - with: - dependency-group: live-test - - name: Start Certomancer Animator daemon - run: | - certomancer --service-url-prefix http://localhost:9000 \ - --config "$CERTOMANCER_CONFIG_PATH" animate & - - name: Start CSC dummy server - run: | - certomancer-csc "$CERTOMANCER_CONFIG_PATH" 8999 2 & - - name: Test with pytest - run: | - python -m pytest --cov=./ --cov-report=xml:python-${{ matrix.python-version }}-live-coverage.xml \ - pyhanko_tests/with_live_certomancer.py \ - pyhanko_tests/with_live_csc_dummy.py - env: - LIVE_CERTOMANCER_HOST_URL: http://localhost:9000 - LIVE_CSC_SCAL2_HOST_URL: http://localhost:8999 - - name: Stash coverage report - uses: actions/upload-artifact@v3 - with: - name: coverage - path: "*-coverage.xml" - smoke-tests: - runs-on: ubuntu-latest - needs: build - steps: - - uses: actions/checkout@v3 - - name: Set up Python - uses: actions/setup-python@v4 - with: - python-version: ${{ env.MAIN_PYTHON_VERSION }} - - name: Download dist artifacts - uses: actions/download-artifact@v3 - with: - name: pyhanko-dist - path: dist/ - - uses: ./.github/actions/test-job-setup - with: - dependency-group: testing-basic - - name: Run smoke tests that should pass without optional dependencies - # We run a couple of the "bread and butter" test modules, and the full CLI test suite except for - # the PKCS#11 parts - run: | - python -m pytest \ - pyhanko_tests/test_signing.py pyhanko_tests/test_diff_analysis.py pyhanko_tests/test_crypt.py \ - pyhanko_tests/test_cms.py pyhanko_tests/cli_tests/*.py - codecov-upload: - runs-on: ubuntu-latest - needs: [pytest-coverage,live-integration-tests] - steps: - # checkout necessary to ensure the uploaded report contains the correct paths - - uses: actions/checkout@v3 - - name: Retrieve coverage reports - uses: actions/download-artifact@v3 - with: - name: coverage - path: ./reports/ - - name: Upload all coverage reports to Codecov - uses: codecov/codecov-action@v3 - with: - directory: ./reports/ - flags: unittests - env_vars: OS,PYTHON - name: codecov-umbrella - - name: Clean up coverage reports - uses: GeekyEggo/delete-artifact@v2 - with: - name: coverage diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 3d813e61..adc6aed4 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -10,7 +10,7 @@ on: jobs: ci: name: Run CI pipeline - uses: MatthiasValvekens/pyHanko/.github/workflows/build-pipeline.yml@master + uses: MatthiasValvekens/pyHanko/.github/workflows/build-pipeline.yml@ci/slsa permissions: actions: read contents: read