postgresql test: fix (#55106)

Commit https://github.com/NixOS/nixpkgs/pull/55097 didn't modify all usages of postgresql/default.nix.

Also, replaced "random" pg with pg11. Random pg was always pg10.
This commit is contained in:
Danylo Hlynskyi 2019-02-03 13:03:53 +02:00 committed by GitHub
parent 448b3c8e8c
commit bd0bb9e497
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -7,7 +7,7 @@ with import ../lib/testing.nix { inherit system pkgs; };
with pkgs.lib;
let
postgresql-versions = import ../../pkgs/servers/sql/postgresql pkgs pkgs;
postgresql-versions = import ../../pkgs/servers/sql/postgresql pkgs;
test-sql = pkgs.writeText "postgresql-test" ''
CREATE EXTENSION pgcrypto; -- just to check if lib loading works
CREATE TABLE sth (
@ -67,12 +67,7 @@ let
};
in
(mapAttrs' (name: package: { inherit name; value=make-postgresql-test name package false;}) postgresql-versions) // (
# just pick one version for the dump all test
let
first = head (attrNames postgresql-versions);
name = "${first}-backup-all";
in {
${name} = make-postgresql-test name postgresql-versions.${first} true;
(mapAttrs' (name: package: { inherit name; value=make-postgresql-test name package false;}) postgresql-versions) // {
postgresql_11-backup-all = make-postgresql-test name postgresql-versions.postgresql_11 true;
}
)