summaryrefslogtreecommitdiffstats
path: root/tests/default.nix
diff options
context:
space:
mode:
Diffstat (limited to 'tests/default.nix')
-rw-r--r--tests/default.nix16
1 files changed, 16 insertions, 0 deletions
diff --git a/tests/default.nix b/tests/default.nix
new file mode 100644
index 0000000..525f936
--- /dev/null
+++ b/tests/default.nix
@@ -0,0 +1,16 @@
+{ makeTest ? import <nixpkgs/nixos/tests/make-test-python.nix>
+, pkgs ? (import <nixpkgs> { })
+}@args:
+let
+ lib = pkgs.lib;
+ makeDiskoTest = (pkgs.callPackage ./lib.nix { inherit makeTest; }).makeDiskoTest;
+ allTestFilenames =
+ builtins.map (lib.removeSuffix ".nix") (
+ builtins.filter
+ (x: lib.hasSuffix ".nix" x && x != "default.nix" && x != "lib.nix")
+ (lib.attrNames (builtins.readDir ./.))
+ );
+
+ allTests = lib.genAttrs (allTestFilenames) (test: import (./. + "/${test}.nix") { inherit makeDiskoTest; });
+in
+allTests