black reformatting #552
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: Test | |
| on: | |
| push: | |
| branches: | |
| - "*" | |
| jobs: | |
| pytest: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Checkout code | |
| uses: actions/checkout@v4 | |
| - name: Set up Python | |
| uses: actions/setup-python@v5 | |
| with: | |
| python-version: "3.10" | |
| - name: Install dependencies | |
| run: pip install -e ./[test] | |
| working-directory: ./gridkit-py | |
| - name: Run pytest | |
| run: python -m pytest tests --cov --verbose | |
| working-directory: ./gridkit-py | |
| - name: Run doctest | |
| run: python -m pytest gridkit/ docs/source/*.rst --doctest-modules | |
| working-directory: ./gridkit-py | |
| - name: Run black check | |
| run: python3 -m black gridkit tests --check | |
| working-directory: ./gridkit-py | |
| - name: Run isort check | |
| run: python3 -m isort gridkit tests --check --profile black | |
| working-directory: ./gridkit-py | |
| - name: Run wordwarden check | |
| run: | | |
| sudo apt update && sudo apt install -y build-essential curl | |
| curl https://sh.rustup.rs -sSf | sh -s -- -y | |
| echo "$HOME/.cargo/bin" >> $GITHUB_PATH | |
| cargo install word_warden | |
| word_warden $(ls ./gridkit-py/gridkit/*.py ./gridkit-py/tests/*.py ./gridkit-py/src/*.rs ./gridkit-rs/src/*.rs) "breakpoint()" "set_trace()" "WIP" "nocheckin" "println(" # wordwarden:skip-line | |
| - name: Upload coverage reports to Codecov | |
| uses: codecov/codecov-action@v3 | |
| env: | |
| CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }} |