diff --git a/pkgs/development/python-modules/pytest-mock/default.nix b/pkgs/development/python-modules/pytest-mock/default.nix index 8d2c24dbd8c2..0f2b0dd6012c 100644 --- a/pkgs/development/python-modules/pytest-mock/default.nix +++ b/pkgs/development/python-modules/pytest-mock/default.nix @@ -1,9 +1,7 @@ { lib, buildPythonPackage, - pythonAtLeast, - pythonOlder, - fetchPypi, + fetchFromGitHub, pytest, pytest-asyncio, pytestCheckHook, @@ -13,14 +11,14 @@ buildPythonPackage rec { pname = "pytest-mock"; - version = "3.14.0"; + version = "3.14.1"; pyproject = true; - disabled = pythonOlder "3.7"; - - src = fetchPypi { - inherit pname version; - hash = "sha256-JxklWh7+zq28BW1r8989HFAVUw+0DPNHwPmvrIhBC9A="; + src = fetchFromGitHub { + owner = "pytest-dev"; + repo = "pytest-mock"; + tag = "v${version}"; + hash = "sha256-aOa/MQAgQePX/NivQ6G37r70sZnqBA+y+GXvPVBxmvs="; }; nativeBuildInputs = [ @@ -35,18 +33,12 @@ buildPythonPackage rec { pytestCheckHook ]; - disabledTests = lib.optionals (pythonAtLeast "3.11") [ - # Regression in 3.11.7 and 3.12.1; https://github.com/pytest-dev/pytest-mock/issues/401 - "test_failure_message_with_name" - "test_failure_message_with_no_name" - ]; - pythonImportsCheck = [ "pytest_mock" ]; meta = with lib; { description = "Thin wrapper around the mock package for easier use with pytest"; homepage = "https://github.com/pytest-dev/pytest-mock"; - changelog = "https://github.com/pytest-dev/pytest-mock/blob/v${version}/CHANGELOG.rst"; + changelog = "https://github.com/pytest-dev/pytest-mock/blob/${src.tag}/CHANGELOG.rst"; license = licenses.mit; maintainers = with maintainers; [ dotlambda ]; };