diff --git a/default.nix b/default.nix index 2e0d0ef..67e44e2 100644 --- a/default.nix +++ b/default.nix @@ -23,6 +23,4 @@ rec { "no failing test" else concatStringsSep "\n" formattedFailureGroups; - - disnixtests = pkgs.callPackage ./tests/disnix/keycloak.nix {}; } diff --git a/docs/tutorials/unittests.md b/docs/tutorials/unittests.md index 5c8a632..fbf88ac 100644 --- a/docs/tutorials/unittests.md +++ b/docs/tutorials/unittests.md @@ -3,4 +3,4 @@ Unit tests are used in Self Host Blocks to check that parsing configurations produce the expected result. -You can find all unit tests under the [tests/](/tests/) directory. +You can find all unit tests under the [tests/unit](/tests/unit) directory. diff --git a/tests/default.nix b/tests/default.nix index da2cae0..a8b24a1 100644 --- a/tests/default.nix +++ b/tests/default.nix @@ -1,12 +1,8 @@ -# to run all tests: -# nix-instantiate --eval --strict . -A tests - { pkgs , utils }: { - haproxy = pkgs.callPackage ./haproxy.nix { inherit utils; }; - keycloak = pkgs.callPackage ./keycloak.nix {}; - keycloak-cli-config = pkgs.callPackage ./keycloak-cli-config.nix {}; + unit = pkgs.callPackage ./unit { inherit utils; }; + integration = pkgs.callPackage ./integration { inherit utils; }; } diff --git a/tests/unit/default.nix b/tests/unit/default.nix new file mode 100644 index 0000000..10c6d32 --- /dev/null +++ b/tests/unit/default.nix @@ -0,0 +1,9 @@ +{ pkgs +, utils +}: + +{ + haproxy = pkgs.callPackage ./haproxy.nix { inherit utils; }; + keycloak = pkgs.callPackage ./keycloak.nix {}; + keycloak-cli-config = pkgs.callPackage ./keycloak-cli-config.nix {}; +} diff --git a/tests/haproxy.nix b/tests/unit/haproxy.nix similarity index 100% rename from tests/haproxy.nix rename to tests/unit/haproxy.nix diff --git a/tests/keycloak-cli-config.nix b/tests/unit/keycloak-cli-config.nix similarity index 100% rename from tests/keycloak-cli-config.nix rename to tests/unit/keycloak-cli-config.nix diff --git a/tests/keycloak.nix b/tests/unit/keycloak.nix similarity index 100% rename from tests/keycloak.nix rename to tests/unit/keycloak.nix