diff options
author | Florian Brandes <florian.brandes@posteo.de> | 2022-04-24 13:17:42 +0200 |
---|---|---|
committer | Florian Brandes <florian.brandes@posteo.de> | 2022-04-27 19:15:08 +0200 |
commit | eef222b8c2f220033fb76aa64cdfd9dcf9d6a3aa (patch) | |
tree | ac2a09cff1ee942b3fc64707c096fae8a0c7d9f3 /nixos/tests/pgadmin4.nix | |
parent | eff62ac1963df80205482aa6d40962f1abdfa832 (diff) |
pgadmin4: fix tests
this commit passes the build dependencies to the pgadmin nixos test for package and regression testing. Also added changelog and some clarifying comments. Signed-off-by: Florian Brandes <florian.brandes@posteo.de>
Diffstat (limited to 'nixos/tests/pgadmin4.nix')
-rw-r--r-- | nixos/tests/pgadmin4.nix | 68 |
1 files changed, 24 insertions, 44 deletions
diff --git a/nixos/tests/pgadmin4.nix b/nixos/tests/pgadmin4.nix index dd4be1d0616c1..6c37bc0502f37 100644 --- a/nixos/tests/pgadmin4.nix +++ b/nixos/tests/pgadmin4.nix @@ -1,4 +1,20 @@ -import ./make-test-python.nix ({ pkgs, lib, ... }: +import ./make-test-python.nix ({ pkgs, lib, buildDeps ? [ ], ... }: + + /* + This test suite replaces the typical pytestCheckHook function in python + packages. Pgadmin4 test suite needs a running and configured postgresql + server. This is why this test exists. + + To not repeat all the python dependencies needed, this test is called directly + from the pgadmin4 derivation, which also passes the currently + used propagatedBuildInputs. + + Unfortunately, there doesn't seem to be an easy way to otherwise include + the needed packages here. + + Also any python Overrides need to be duplicated here, too. + + */ let pgadmin4SrcDir = "/pgadmin"; @@ -47,50 +63,14 @@ import ./make-test-python.nix ({ pkgs, lib, ... }: postgresql chromedriver chromium + # include the same packages as in pgadmin minus speaklater3 (python3.withPackages - (ps: with pythonPackages; [ - selenium - testtools - testscenarios - flask - flask-babelex - flask-babel - flask-gravatar - flask_login - flask_mail - flask_migrate - flask_sqlalchemy - flask_wtf - flask-compress - passlib - pytz - simplejson - six - sqlparse - wtforms - flask-paranoid - psutil - psycopg2 - python-dateutil - sqlalchemy - itsdangerous - flask-security-too - bcrypt - cryptography - sshtunnel - ldap3 - gssapi - flask-socketio - eventlet - httpagentparser - user-agents - wheel - authlib - qrcode - pillow - pyotp - boto3 - ]) + (ps: buildDeps ++ + [ + # test suite package requirements + pythonPackages.testscenarios + pythonPackages.selenium + ]) ) ]; services.postgresql = { |