feat: add testing infrastructure
This commit is contained in:
parent
d04a0125d5
commit
c875dd77fe
4 changed files with 661 additions and 1 deletions
20
flake.nix
20
flake.nix
|
@ -15,6 +15,10 @@
|
|||
url = "github:cachix/pre-commit-hooks.nix";
|
||||
inputs.nixpkgs.follows = "nixpkgs";
|
||||
};
|
||||
nixt = {
|
||||
url = "github:nix-community/nixt";
|
||||
inputs.nixpkgs.follows = "nixpkgs";
|
||||
};
|
||||
};
|
||||
|
||||
outputs =
|
||||
|
@ -28,6 +32,18 @@
|
|||
"x86_64-linux"
|
||||
"aarch64-linux"
|
||||
];
|
||||
flake.__nixt = inputs.nixt.lib.grow {
|
||||
blocks = import ./tests {
|
||||
inherit (inputs) nixt;
|
||||
pkgs = import inputs.nixpkgs {
|
||||
system = "x86_64-linux";
|
||||
config.allowUnfree = true;
|
||||
overlays = [
|
||||
self.overlays.default
|
||||
];
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
flake.modules = {
|
||||
flake = {
|
||||
|
@ -76,6 +92,10 @@
|
|||
package = statix;
|
||||
help = "Lint nix code";
|
||||
}
|
||||
{
|
||||
package = inputs.nixt.packages.${system}.default;
|
||||
help = "Lint nix code";
|
||||
}
|
||||
{
|
||||
package = deadnix;
|
||||
help = "Find unused expressions in nix code";
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue