Improve tests for non-flakes #108
Workflow file for this run
This file contains 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: "ci" | |
on: | |
workflow_dispatch: # allows manual triggering | |
pull_request: | |
branches: [main] | |
paths-ignore: | |
- '**.md' | |
push: | |
branches: [main] | |
paths-ignore: | |
- '**.md' | |
merge_group: | |
jobs: | |
dependencies: | |
runs-on: ubuntu-latest | |
environment: cachix | |
steps: | |
- uses: actions/checkout@v4 | |
with: | |
fetch-depth: 0 | |
- uses: cachix/install-nix-action@V27 | |
with: | |
extra_nix_config: | | |
access-tokens = github.com=${{ secrets.GITHUB_TOKEN }} | |
- uses: cachix/cachix-action@v15 | |
with: | |
name: kenji | |
authToken: '${{ secrets.CACHIX_AUTH_TOKEN }}' | |
- uses: DeterminateSystems/magic-nix-cache-action@v7 | |
with: | |
diagnostic-endpoint: "" | |
- name: "build dependencies" | |
run: nix build .#cargoArtifacts -Lvv --no-update-lock-file | |
formatting: | |
runs-on: ubuntu-latest | |
environment: cachix | |
steps: | |
- uses: actions/checkout@v4 | |
with: | |
fetch-depth: 0 | |
- uses: cachix/install-nix-action@V27 | |
with: | |
extra_nix_config: | | |
access-tokens = github.com=${{ secrets.GITHUB_TOKEN }} | |
- uses: cachix/cachix-action@v15 | |
with: | |
name: kenji | |
authToken: '${{ secrets.CACHIX_AUTH_TOKEN }}' | |
- uses: DeterminateSystems/magic-nix-cache-action@v7 | |
with: | |
diagnostic-endpoint: "" | |
- name: "check formatting" | |
run: nix build .#checks.x86_64-linux.treefmt -Lvv --no-update-lock-file | |
tests: | |
runs-on: ubuntu-latest | |
environment: cachix | |
needs: ['formatting', 'dependencies'] | |
steps: | |
- uses: actions/checkout@v4 | |
with: | |
fetch-depth: 0 | |
- uses: cachix/install-nix-action@V27 | |
with: | |
extra_nix_config: | | |
access-tokens = github.com=${{ secrets.GITHUB_TOKEN }} | |
- uses: cachix/cachix-action@v15 | |
with: | |
name: kenji | |
authToken: '${{ secrets.CACHIX_AUTH_TOKEN }}' | |
- uses: DeterminateSystems/magic-nix-cache-action@v7 | |
with: | |
diagnostic-endpoint: "" | |
- name: "run tests" | |
run: nix build .#cargoTest -Lvv --no-update-lock-file | |
docs: | |
runs-on: ubuntu-latest | |
environment: cachix | |
needs: ['formatting', 'dependencies'] | |
steps: | |
- uses: actions/checkout@v4 | |
with: | |
fetch-depth: 0 | |
- uses: cachix/install-nix-action@V27 | |
with: | |
extra_nix_config: | | |
access-tokens = github.com=${{ secrets.GITHUB_TOKEN }} | |
- uses: cachix/cachix-action@v15 | |
with: | |
name: kenji | |
authToken: '${{ secrets.CACHIX_AUTH_TOKEN }}' | |
- uses: DeterminateSystems/magic-nix-cache-action@v7 | |
with: | |
diagnostic-endpoint: "" | |
- name: "build cargo documentation" | |
run: nix build .#cargoDoc -Lvv --no-update-lock-file | |
clippy: | |
runs-on: ubuntu-latest | |
environment: cachix | |
needs: ['formatting', 'dependencies'] | |
steps: | |
- uses: actions/checkout@v4 | |
with: | |
fetch-depth: 0 | |
- uses: cachix/install-nix-action@V27 | |
with: | |
extra_nix_config: | | |
access-tokens = github.com=${{ secrets.GITHUB_TOKEN }} | |
- uses: cachix/cachix-action@v15 | |
with: | |
name: kenji | |
authToken: '${{ secrets.CACHIX_AUTH_TOKEN }}' | |
- uses: DeterminateSystems/magic-nix-cache-action@v7 | |
with: | |
diagnostic-endpoint: "" | |
- name: "run cargo clippy" | |
run: nix build .#cargoClippy -Lvv --no-update-lock-file | |
flake-edit: | |
runs-on: ubuntu-latest | |
environment: cachix | |
needs: ['formatting', 'dependencies' ] | |
steps: | |
- uses: actions/checkout@v4 | |
with: | |
fetch-depth: 0 | |
- uses: cachix/install-nix-action@V27 | |
with: | |
extra_nix_config: | | |
access-tokens = github.com=${{ secrets.GITHUB_TOKEN }} | |
- uses: cachix/cachix-action@v15 | |
with: | |
name: kenji | |
authToken: '${{ secrets.CACHIX_AUTH_TOKEN }}' | |
- uses: DeterminateSystems/magic-nix-cache-action@v7 | |
with: | |
diagnostic-endpoint: "" | |
- name: "build flake-edit" | |
run: nix build .#cargoClippy -Lvv --no-update-lock-file | |
devshells: | |
runs-on: ubuntu-latest | |
environment: cachix | |
needs: ['formatting'] | |
steps: | |
- uses: actions/checkout@v4 | |
with: | |
fetch-depth: 0 | |
- uses: cachix/install-nix-action@V27 | |
with: | |
extra_nix_config: | | |
access-tokens = github.com=${{ secrets.GITHUB_TOKEN }} | |
- uses: cachix/cachix-action@v15 | |
with: | |
name: kenji | |
authToken: '${{ secrets.CACHIX_AUTH_TOKEN }}' | |
- uses: DeterminateSystems/magic-nix-cache-action@v7 | |
with: | |
diagnostic-endpoint: "" | |
- name: "build devshells" | |
run: nix develop .#full -Lvv --no-update-lock-file |