2022-01-13 20:06:32 +00:00
|
|
|
{ lib
|
|
|
|
, buildPythonPackage
|
|
|
|
, fetchFromGitHub
|
|
|
|
, packaging
|
|
|
|
, pytest
|
|
|
|
, setuptools-scm
|
2024-04-21 15:54:59 +00:00
|
|
|
, pytest7CheckHook
|
2022-04-27 09:35:20 +00:00
|
|
|
, pythonOlder
|
2022-01-13 20:06:32 +00:00
|
|
|
}:
|
2021-01-09 10:05:03 +00:00
|
|
|
|
|
|
|
buildPythonPackage rec {
|
|
|
|
pname = "pytest-snapshot";
|
2022-04-27 09:35:20 +00:00
|
|
|
version = "0.9.0";
|
2022-01-13 20:06:32 +00:00
|
|
|
format = "setuptools";
|
2021-01-09 10:05:03 +00:00
|
|
|
|
2022-04-27 09:35:20 +00:00
|
|
|
disabled = pythonOlder "3.5";
|
|
|
|
|
2022-01-13 20:06:32 +00:00
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "joseph-roitman";
|
|
|
|
repo = pname;
|
2022-04-27 09:35:20 +00:00
|
|
|
rev = "refs/tags/v${version}";
|
2023-03-15 16:39:30 +00:00
|
|
|
hash = "sha256-0PZu9wL29iEppLxxbl4D0E4WfOHe61KUUld003cRBRU=";
|
2021-01-09 10:05:03 +00:00
|
|
|
};
|
|
|
|
|
2022-01-13 20:06:32 +00:00
|
|
|
nativeBuildInputs = [
|
|
|
|
setuptools-scm
|
|
|
|
];
|
2021-04-05 15:23:46 +00:00
|
|
|
|
2022-01-13 20:06:32 +00:00
|
|
|
buildInputs = [
|
|
|
|
pytest
|
|
|
|
];
|
2021-01-09 10:05:03 +00:00
|
|
|
|
2022-01-13 20:06:32 +00:00
|
|
|
propagatedBuildInputs = [
|
|
|
|
packaging
|
|
|
|
];
|
|
|
|
|
2023-02-02 18:25:31 +00:00
|
|
|
nativeCheckInputs = [
|
2024-04-21 15:54:59 +00:00
|
|
|
# https://github.com/joseph-roitman/pytest-snapshot/issues/71
|
|
|
|
pytest7CheckHook
|
2022-01-13 20:06:32 +00:00
|
|
|
];
|
|
|
|
|
|
|
|
pythonImportsCheck = [
|
|
|
|
"pytest_snapshot"
|
|
|
|
];
|
2021-01-09 10:05:03 +00:00
|
|
|
|
|
|
|
meta = with lib; {
|
|
|
|
description = "A plugin to enable snapshot testing with pytest";
|
|
|
|
homepage = "https://github.com/joseph-roitman/pytest-snapshot/";
|
|
|
|
license = licenses.mit;
|
2023-08-04 22:07:22 +00:00
|
|
|
maintainers = with maintainers; [ ];
|
2021-01-09 10:05:03 +00:00
|
|
|
};
|
|
|
|
}
|