Updated specmatic core to 2.0.49 #151
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Run tests on different Python 🐍 versions and operating systems. | |
on: | |
push: | |
branches: | |
- main | |
jobs: | |
test: | |
name: Run Tests | |
permissions: | |
checks: write | |
contents: read | |
strategy: | |
matrix: | |
os: [ ubuntu-latest] | |
python-version: [3.12] | |
runs-on: ${{ matrix.os }} | |
steps: | |
- name: Set up JDK 17 | |
uses: actions/setup-java@v4 | |
with: | |
java-version: '17' | |
distribution: 'oracle' | |
- uses: actions/checkout@v4 | |
- name: Set up Python | |
uses: actions/setup-python@v4 | |
with: | |
python-version: ${{ matrix.python-version }} | |
cache: 'pip' | |
- name: Install pypa/build | |
run: >- | |
python -m pip install build --user | |
- name: Run pip install | |
run: pip install -r requirements.txt | |
- name: Run contract as tests with Specmatic Python | |
run: coverage run --branch -m pytest test -v -s --junitxml contract-test-reports/TEST-junit-jupiter.xml | |
- name: Publish contract test report | |
uses: mikepenz/action-junit-report@v4 | |
if: always() | |
with: | |
report_paths: '**/contract-test-reports/TEST-*.xml' | |
- name: Generate coverage report | |
run: coverage html -d coverage-report | |
- name: Upload coverage report | |
uses: actions/upload-artifact@v4 | |
with: | |
name: coverage-report | |
path: coverage-report |