From f0af08faff77c44bc397f685ee153ee31cee35d7 Mon Sep 17 00:00:00 2001 From: Martin Weinelt Date: Sat, 9 Oct 2021 15:43:35 +0200 Subject: [PATCH] python3Packages.makefun: fix build, enable tests --- .../python-modules/makefun/default.nix | 18 ++++++++++++------ 1 file changed, 12 insertions(+), 6 deletions(-) diff --git a/pkgs/development/python-modules/makefun/default.nix b/pkgs/development/python-modules/makefun/default.nix index 8287d1c6e7ca..aeb13abd0dfe 100644 --- a/pkgs/development/python-modules/makefun/default.nix +++ b/pkgs/development/python-modules/makefun/default.nix @@ -2,6 +2,7 @@ , fetchPypi , buildPythonPackage , setuptools-scm +, pytestCheckHook }: buildPythonPackage rec { @@ -13,13 +14,18 @@ buildPythonPackage rec { sha256 = "4d0e90ca3fdbdeb6a4a0891e2da7d4b8e80386e19e6db91ce29b8aa5c876ecfe"; }; - nativeBuildInputs = [ setuptools-scm ]; + postPatch = '' + substituteInPlace setup.cfg \ + --replace "pytest-runner" "" + ''; - # Disabling tests for now due to various (transitive) dependencies on modules - # from @smarie which are, as of yet, not part of nixpkgs. Also introduces - # a tricky dependency: makefun tests depend on pytest-cases, installing - # pytest-cases depends on makefun. - doCheck = false; + nativeBuildInputs = [ + setuptools-scm + ]; + + checkInputs = [ + pytestCheckHook + ]; pythonImportsCheck = [ "makefun" ];