Files
nixpkgs/pkgs/development/python-modules/notifications-python-client/default.nix
Guillaume Girol 33afbf39f6 treewide: switch to nativeCheckInputs
checkInputs used to be added to nativeBuildInputs. Now we have
nativeCheckInputs to do that instead. Doing this treewide change allows
to keep hashes identical to before the introduction of
nativeCheckInputs.
2023-01-21 12:00:00 +00:00

59 lines
1.0 KiB
Nix

{ lib
, buildPythonPackage
, docopt
, fetchFromGitHub
, freezegun
, mock
, pyjwt
, pytest-mock
, pytestCheckHook
, pythonOlder
, requests
, requests-mock
}:
buildPythonPackage rec {
pname = "notifications-python-client";
version = "6.4.1";
format = "setuptools";
disabled = pythonOlder "3.8";
src = fetchFromGitHub {
owner = "alphagov";
repo = pname;
rev = version;
sha256 = "sha256-HEHerdwplsPAld23Al8sUARu4T5IJLmY5kucAz2791c=";
};
propagatedBuildInputs = [
docopt
pyjwt
requests
];
nativeCheckInputs = [
freezegun
mock
pytest-mock
pytestCheckHook
requests-mock
];
postPatch = ''
substituteInPlace setup.py \
--replace "'pytest-runner'" ""
'';
pythonImportsCheck = [
"notifications_python_client"
];
meta = with lib; {
description = "Python client for the GOV.UK Notify API";
homepage = "https://github.com/alphagov/notifications-python-client";
license = with licenses; [ mit ];
maintainers = with maintainers; [ fab ];
};
}