diff --git a/nixos/tests/initdb.nix b/nixos/tests/initdb.nix deleted file mode 100644 index e7c83dc4002c..000000000000 --- a/nixos/tests/initdb.nix +++ /dev/null @@ -1,19 +0,0 @@ -import ./make-test-python.nix ({ pkgs, latestKernel ? false, ... }: { - name = "pg-initdb"; - - machine = {...}: - { - documentation.enable = false; - services.postgresql.enable = true; - services.postgresql.package = pkgs.postgresql_9_6; - environment.pathsToLink = [ - "/share/postgresql" - ]; - }; - - testScript = '' - machine.start() - machine.succeed("sudo -u postgres initdb -D /tmp/testpostgres2") - machine.shutdown() - ''; -}) diff --git a/nixos/tests/postgresql.nix b/nixos/tests/postgresql.nix index 5ba2d38773bb..3201e22555ea 100644 --- a/nixos/tests/postgresql.nix +++ b/nixos/tests/postgresql.nix @@ -76,6 +76,9 @@ let "stat -c '%a' /var/backup/postgresql/${backupName}.sql.gz | grep 600", ) + with subtest("Initdb works"): + machine.succeed("sudo -u postgres initdb -D /tmp/testpostgres2") + machine.shutdown() '';