(test) add more tests for pytryfi and hass integration flow (#20) #74
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: "Validation And Formatting" | |
| on: | |
| push: | |
| pull_request: | |
| workflow_dispatch: | |
| jobs: | |
| ci: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v4.2.2 | |
| name: Download repo | |
| with: | |
| fetch-depth: 0 | |
| # Install Tools | |
| - name: Install uv | |
| uses: astral-sh/setup-uv@v6 | |
| with: | |
| enable-cache: true | |
| - uses: actions/setup-python@v5.6.0 | |
| name: Setup Python | |
| with: | |
| python-version-file: ".python-version" | |
| - name: Install project dependencies | |
| run: uv sync --locked --all-extras --dev | |
| - name: Syntax check source files | |
| uses: astral-sh/ruff-action@v3 | |
| - name: Run tests | |
| # Unshare to prevent any accidental network calls to the real API | |
| run: sudo unshare --net sudo -u $USER $(which uv) run pytest tests | |
| - uses: hacs/action@22.5.0 | |
| with: | |
| category: integration |