···11{ inputs, ... }:
22+let
33+ flakeModule = {
44+ systems = import inputs.systems;
55+ imports = [
66+ ./perSystem-lib.nix
77+ ./tests.nix
88+ ./treefmt.nix
99+ ];
1010+ };
1111+1212+ # Tests are defined by target, and imported bellow by `inputs.target.flakeModules.nix-unit`.
1313+ # See example/flake.nix or https://github.com/vic/import-tree/tree/main/checks/default.nix
1414+ targetTest = inputs.target.flakeModules.nix-unit or { };
1515+in
216{
33- systems = import inputs.systems;
417 imports = [
55- ./perSystem-lib.nix
66- ./tests.nix
77- ./treefmt.nix
1818+ flakeModule
1919+ targetTest
820 ];
2121+2222+ flake.flakeModules.default = flakeModule;
923}
-3
tests.nix
···11{ inputs, ... }:
22{
33 imports = [
44- # Tests are defined by target, and imported bellow by `inputs.target.flakeModules.nix-unit`.
55- # See example/flake.nix or https://github.com/vic/import-tree/tree/main/checks/default.nix
66- inputs.target.flakeModules.nix-unit
74 inputs.nix-unit.modules.flake.default
85 ];
96