From 2a12e9dacc87bfbd3c997462945a2f7aa967763b Mon Sep 17 00:00:00 2001 From: aszlig <aszlig@redmoonstudios.org> Date: Fri, 29 Jan 2016 17:20:25 +0100 Subject: [PATCH] python-packages/poezio: Fix tests Poezio doesn't install the files required for running the tests, but also while building with Nix we don't end up getting valid shared objects within the temporary build directory. So we now running "make test" (which does "py.test -v test/") with a PYTHONPATH that adds the /poezio directory of the path in site-packages to make sure that the test runner is able to import the shared objects. Signed-off-by: aszlig <aszlig@redmoonstudios.org> Cc: @lancelotsix --- pkgs/top-level/python-packages.nix | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/pkgs/top-level/python-packages.nix b/pkgs/top-level/python-packages.nix index 5e320e3f32b1..50f5288155d5 100644 --- a/pkgs/top-level/python-packages.nix +++ b/pkgs/top-level/python-packages.nix @@ -24472,6 +24472,10 @@ in modules // { buildInputs = with self; [ pytest ]; propagatedBuildInputs = with self ; [ aiodns slixmpp pyinotify potr ]; + checkPhase = '' + PYTHONPATH="$PYTHONPATH:$out/${python.sitePackages}/poezio" make test + ''; + patches = let patch_base = ../development/python-modules/poezio; in [ "${patch_base}/make_default_config_writable.patch" ];