Update workflow for wt2526 (#1) #10
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: Testing workflow | |
| on: [push, pull_request] | |
| jobs: | |
| style: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v6 | |
| - uses: actions/setup-python@v6 | |
| with: | |
| python-version: '3.10' | |
| - name: "Install style checker" | |
| run: pip install black | |
| - name: "Run style check" | |
| run: black --check . | |
| build: | |
| needs: style | |
| runs-on: ubuntu-latest | |
| env: | |
| PROJECT_NAME: "Automation Lecture" | |
| steps: | |
| - name: "Run build phase" | |
| run: echo "Building project $PROJECT_NAME" | |
| test: | |
| # needs: build # We would normally not run the tests if the build fails, | |
| # but letting them go through, for demonstration purposes. | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v6 | |
| - uses: actions/setup-python@v6 | |
| with: | |
| python-version: '3.10' | |
| - name: "Run unittest" | |
| run: python -m unittest |