flake: expose tests as checks output
This commit is contained in:
15
flake.nix
15
flake.nix
@@ -235,6 +235,10 @@
|
|||||||
buildPlatform = builtins.currentSystem;
|
buildPlatform = builtins.currentSystem;
|
||||||
};
|
};
|
||||||
lib = import ./modules/lib.nix { inherit inputs pkgs service_configs; };
|
lib = import ./modules/lib.nix { inherit inputs pkgs service_configs; };
|
||||||
|
testSuite = import ./tests/tests.nix {
|
||||||
|
inherit pkgs lib inputs;
|
||||||
|
config = self.nixosConfigurations.muffin.config;
|
||||||
|
};
|
||||||
in
|
in
|
||||||
{
|
{
|
||||||
formatter.x86_64-linux = nixpkgs.legacyPackages.x86_64-linux.nixfmt-tree;
|
formatter.x86_64-linux = nixpkgs.legacyPackages.x86_64-linux.nixfmt-tree;
|
||||||
@@ -319,14 +323,9 @@
|
|||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
packages.${system} =
|
checks.${system} = testSuite;
|
||||||
let
|
|
||||||
testSuite = import ./tests/tests.nix {
|
packages.${system} = {
|
||||||
inherit pkgs lib inputs;
|
|
||||||
config = self.nixosConfigurations.muffin.config;
|
|
||||||
};
|
|
||||||
in
|
|
||||||
{
|
|
||||||
tests = pkgs.linkFarm "all-tests" (
|
tests = pkgs.linkFarm "all-tests" (
|
||||||
pkgs.lib.mapAttrsToList (name: test: {
|
pkgs.lib.mapAttrsToList (name: test: {
|
||||||
name = name;
|
name = name;
|
||||||
|
|||||||
Reference in New Issue
Block a user