fix: build cleanup and terminate on failure #24
This file contains hidden or 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: CLI Tests | |
| on: | |
| pull_request: | |
| paths: | |
| - "cli/**" | |
| - ".github/workflows/cli-tests.yaml" | |
| push: | |
| branches: [main] | |
| paths: | |
| - "cli/**" | |
| - ".github/workflows/cli-tests.yaml" | |
| permissions: | |
| contents: read | |
| jobs: | |
| pytest: | |
| name: Pytest (cli) | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v6 | |
| - name: Set up Python | |
| uses: actions/setup-python@v5 | |
| with: | |
| python-version: "3.12" | |
| - name: Install dependencies | |
| run: | | |
| python -m pip install --upgrade pip | |
| python -m pip install boto3 click pyyaml pytest moto pytest-cov | |
| - name: Run pytest | |
| run: | | |
| pytest --cov=cli --cov-report=xml cli | |
| # - name: Upload coverage to Codecov | |
| # uses: codecov/codecov-action@v4 | |
| # with: | |
| # files: ./coverage.xml | |
| # flags: cli | |
| # fail_ci_if_error: false | |
| # env: | |
| # CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }} |