diff --git a/pkgs/development/python-modules/Pygments/default.nix b/pkgs/development/python-modules/Pygments/default.nix index a879aef02266..48d74fddd436 100644 --- a/pkgs/development/python-modules/Pygments/default.nix +++ b/pkgs/development/python-modules/Pygments/default.nix @@ -2,6 +2,8 @@ , buildPythonPackage , fetchPypi , docutils +, pytestCheckHook +, doCheck ? true }: buildPythonPackage rec { @@ -15,8 +17,8 @@ buildPythonPackage rec { propagatedBuildInputs = [ docutils ]; - # Circular dependency with sphinx - doCheck = false; + inherit doCheck; + checkInputs = [ pytestCheckHook ]; meta = { homepage = "https://pygments.org/"; diff --git a/pkgs/top-level/python-packages.nix b/pkgs/top-level/python-packages.nix index eda6869c4728..2650c0b565c6 100644 --- a/pkgs/top-level/python-packages.nix +++ b/pkgs/top-level/python-packages.nix @@ -6415,18 +6415,24 @@ in { pytest_5 = callPackage ../development/python-modules/pytest/5.nix { - # hypothesis tests require pytest that causes dependency cycle + # hypothesis & pygments tests require pytest that causes dependency cycle hypothesis = self.hypothesis.override { doCheck = false; }; + pygments = self.pygments.override { + doCheck = false; + }; }; pytest_6 = callPackage ../development/python-modules/pytest { - # hypothesis tests require pytest that causes dependency cycle + # hypothesis & pygments tests require pytest that causes dependency cycle hypothesis = self.hypothesis.override { doCheck = false; }; + pygments = self.pygments.override { + doCheck = false; + }; }; pytest_6_1 = self.pytest_6.overridePythonAttrs (oldAttrs: rec {