diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index c006e8f..1363a91 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -54,3 +54,12 @@ jobs: python -m pip install .[doc] - name: Build the documentation run: make -C doc html man + + nix: + runs-on: ubuntu-latest + steps: + - name: Install Nix + uses: cachix/install-nix-action@v20 + - uses: actions/checkout@v3 + - name: Build the nix derivation (also runs the tests) + run: nix build --print-build-logs diff --git a/flake.nix b/flake.nix index e388aab..f48e883 100644 --- a/flake.nix +++ b/flake.nix @@ -13,6 +13,9 @@ cp -r $src/khard/data $out/lib/python*/site-packages/khard ''; src = ./.; + pyproject = true; + doCheck = true; + checkPhase = "python -m unittest -v"; }); devShells.x86_64-linux.release = let pkgs = nixpkgs.legacyPackages.x86_64-linux; in