-
Notifications
You must be signed in to change notification settings - Fork 1
46 lines (44 loc) · 2.21 KB
/
ci.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
name: "Test the inspector against a corpus"
on:
push:
branches:
- main
pull_request:
jobs:
flakehub-publish:
runs-on: "ubuntu-latest"
permissions:
id-token: "write"
contents: "read"
steps:
- uses: "actions/checkout@v4"
- uses: "DeterminateSystems/nix-installer-action@main"
- uses: "DeterminateSystems/magic-nix-cache-action@main"
- name: Check formatting
if: success() || failure()
run: |
nix run nixpkgs#nixpkgs-fmt -- --check .
- name: Ensure evaluating DeterminateSystems/flake-checker/=0.1.19 without output paths produces the right result
if: success() || failure()
run: |
nix eval --json \
--override-input flake https://flakehub.com/f/DeterminateSystems/flake-checker/=0.1.19 \
--no-write-lock-file '.#contents.excludingOutputPaths' \
| nix run nixpkgs\#gron > corpus/DeterminateSystems/flake-checker/=0.1.19/excluding.output
diff corpus/DeterminateSystems/flake-checker/=0.1.19/excluding.expect corpus/DeterminateSystems/flake-checker/=0.1.19/excluding.output
- name: Ensure evaluating DeterminateSystems/fh/=0.1.12 without output paths produces the right result
if: success() || failure()
run: |
nix eval --json \
--override-input flake https://flakehub.com/f/DeterminateSystems/fh/=0.1.12 \
--no-write-lock-file '.#contents.excludingOutputPaths' \
| nix run nixpkgs\#gron > corpus/DeterminateSystems/fh/=0.1.12/excluding.output
diff corpus/DeterminateSystems/fh/=0.1.12/excluding.expect corpus/DeterminateSystems/fh/=0.1.12/excluding.output
- name: Ensure evaluating DeterminateSystems/fh/=0.1.12 with output paths produces the right result
if: success() || failure()
run: |
nix eval --json \
--override-input flake https://flakehub.com/f/DeterminateSystems/fh/=0.1.12 \
--no-write-lock-file '.#contents.includingOutputPaths' \
| nix run nixpkgs\#gron > corpus/DeterminateSystems/fh/=0.1.12/including.output
diff corpus/DeterminateSystems/fh/=0.1.12/including.expect corpus/DeterminateSystems/fh/=0.1.12/including.output