2021-12-03 23:02:15 +09:00
|
|
|
name: Test
|
|
|
|
on:
|
2024-09-19 22:34:48 +09:00
|
|
|
pull_request:
|
|
|
|
paths:
|
|
|
|
- '**/*.nix'
|
2021-12-03 23:02:15 +09:00
|
|
|
push:
|
2024-09-19 22:34:48 +09:00
|
|
|
branches:
|
|
|
|
- master
|
2021-12-03 23:02:15 +09:00
|
|
|
paths:
|
2024-09-19 22:26:33 +09:00
|
|
|
- '**/*.nix'
|
2022-12-02 13:04:18 +09:00
|
|
|
workflow_dispatch:
|
2021-12-03 23:02:15 +09:00
|
|
|
jobs:
|
|
|
|
check:
|
2024-09-19 22:29:32 +09:00
|
|
|
strategy:
|
|
|
|
matrix:
|
|
|
|
os:
|
|
|
|
- ubuntu-latest
|
|
|
|
- macos-latest
|
|
|
|
runs-on: ${{ matrix.os }}
|
2021-12-03 23:02:15 +09:00
|
|
|
steps:
|
2024-09-19 22:28:14 +09:00
|
|
|
- uses: actions/checkout@v4
|
|
|
|
- uses: cachix/install-nix-action@V28
|
2024-09-19 22:26:33 +09:00
|
|
|
with:
|
|
|
|
nix_path: nixpkgs=channel:nixos-unstable
|
|
|
|
extra_nix_config: |
|
|
|
|
access-tokens = github.com=${{ secrets.GITHUB_TOKEN }}
|
|
|
|
- name: Run tests
|
|
|
|
run: nix-instantiate --eval --strict test/test.nix
|
|
|
|
- name: Test parameter parsing
|
|
|
|
run: nix-instantiate --eval --strict test/testParams.nix
|
|
|
|
- name: Check the derivation
|
2024-09-19 22:39:24 +09:00
|
|
|
run: nix flake check --no-write-lock-file --override-input org-babel "path:$PWD/.."
|
2024-09-19 22:26:45 +09:00
|
|
|
working-directory: test
|