Write daily CSN summary #35
Workflow file for this run
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: Run pytest | |
| on: | |
| push: | |
| branches: [main, dev] | |
| pull_request: | |
| branches: [main, dev] | |
| workflow_dispatch: | |
| jobs: | |
| build: | |
| name: Run pytest | |
| runs-on: ubuntu-latest | |
| env: | |
| PROJECT_ROOT: ${{ github.workspace }}/waveform-controller | |
| steps: | |
| - uses: actions/checkout@v5 | |
| with: | |
| path: waveform-controller | |
| - name: Checkout PIXL dependency | |
| uses: actions/checkout@v5 | |
| with: | |
| repository: SAFEHR-data/PIXL | |
| ref: main | |
| path: PIXL | |
| - name: Install uv | |
| uses: astral-sh/setup-uv@v7 | |
| with: | |
| version: "0.9.26" | |
| python-version: "3.13" | |
| enable-cache: true | |
| - name: Make a venv | |
| working-directory: waveform-controller | |
| run: uv venv | |
| - name: Install with dependencies | |
| working-directory: waveform-controller | |
| run: uv pip install '.[dev]' | |
| - name: Prepare config env files for compose | |
| working-directory: waveform-controller | |
| run: | | |
| mkdir -p ../config | |
| cp config.EXAMPLE/exporter.env.EXAMPLE ../config/exporter.env | |
| cp config.EXAMPLE/hasher.env.EXAMPLE ../config/hasher.env | |
| cp config.EXAMPLE/controller.env.EXAMPLE ../config/controller.env | |
| - name: Set up Docker Buildx | |
| uses: docker/setup-buildx-action@v3 | |
| - name: Build exporter image (cached) | |
| uses: docker/build-push-action@v6 | |
| with: | |
| context: . | |
| file: waveform-controller/Dockerfile | |
| target: waveform_exporter | |
| cache-from: type=gha | |
| cache-to: type=gha,mode=max | |
| - name: Run the tests | |
| working-directory: waveform-controller | |
| run: uv run pytest tests |