fix: TOOLS-3121 Add error handling for masking-show command failures … #790
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: Tests | |
| on: | |
| push: | |
| branches: ["*"] | |
| pull_request: | |
| branches: ["dependabot/**"] | |
| jobs: | |
| build: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v4 | |
| with: | |
| submodules: true | |
| - name: Get Python version from Pipfile | |
| run: echo "PYTHON_VERSION=$(grep "python_version" Pipfile | cut -d ' ' -f 3 - | tr -d '"')" >> $GITHUB_ENV | |
| - name: Set up Python ${{ env.PYTHON_VERSION }} | |
| uses: actions/setup-python@v3 | |
| with: | |
| python-version: ${{ env.PYTHON_VERSION }} | |
| - name: Install dependencies | |
| run: | | |
| python -m pip install pipenv | |
| pipenv install --dev | |
| - name: Build | |
| run: | | |
| make | |
| - name: Tests with coverage report | |
| env: | |
| FEATKEY: ${{ secrets.TEST_FEAT_KEY }} | |
| run: | | |
| pipenv run bash -c "make coverage" | |
| pipenv run bash -c "coverage xml" | |
| - name: Upload Collectinfo for Debugging | |
| if: failure() | |
| uses: actions/upload-artifact@v4 | |
| with: | |
| name: test_collectinfo | |
| path: /tmp/asadm_test* | |
| if-no-files-found: error | |
| - name: Upload Health Struct for Debugging | |
| if: failure() | |
| uses: actions/upload-artifact@v4 | |
| with: | |
| name: health_files | |
| path: "*_health_input.txt" | |
| if-no-files-found: error | |
| - name: Upload coverage report to Codecov | |
| uses: codecov/codecov-action@v3 | |
| with: | |
| files: coverage.xml | |
| fail_ci_if_error: false |