diff --git a/pkgs/development/python-modules/certifi/default.nix b/pkgs/development/python-modules/certifi/default.nix index 0aa2a321b832..c80ba08503d4 100644 --- a/pkgs/development/python-modules/certifi/default.nix +++ b/pkgs/development/python-modules/certifi/default.nix @@ -30,16 +30,15 @@ buildPythonPackage rec { ln -snvf "${cacert}/etc/ssl/certs/ca-bundle.crt" "certifi/cacert.pem" ''; + propagatedNativeBuildInputs = [ + # propagate cacerts setup-hook to set up `NIX_SSL_CERT_FILE` + cacert + ]; + checkInputs = [ pytestCheckHook ]; - preCheck = '' - # NIX_SSL_CERT_FILE is set to /no-cert-file.crt during build, which - # breaks the tests - unset NIX_SSL_CERT_FILE - ''; - pythonImportsCheck = [ "certifi" ]; diff --git a/pkgs/development/python-modules/sphinx/default.nix b/pkgs/development/python-modules/sphinx/default.nix index 5edfaa251515..5a27f04bd0ee 100644 --- a/pkgs/development/python-modules/sphinx/default.nix +++ b/pkgs/development/python-modules/sphinx/default.nix @@ -95,9 +95,6 @@ buildPythonPackage rec { preCheck = '' export HOME=$(mktemp -d) - - # Unset dummy cert file path set in stdenv, that confuses certifi - unset NIX_SSL_CERT_FILE ''; disabledTests = [