mirror of
https://github.com/NixOS/nixpkgs.git
synced 2025-07-13 21:50:33 +03:00
python310Packages.jsonpatch: enable tests
- add pythonImportsCheck - disable on obsolete Python releases
This commit is contained in:
parent
0dbb26a391
commit
13a4a8702c
1 changed files with 29 additions and 9 deletions
|
@ -1,25 +1,45 @@
|
|||
{ lib
|
||||
, buildPythonPackage
|
||||
, fetchPypi
|
||||
, fetchFromGitHub
|
||||
, jsonpointer
|
||||
, pytestCheckHook
|
||||
, pythonOlder
|
||||
}:
|
||||
|
||||
buildPythonPackage rec {
|
||||
pname = "jsonpatch";
|
||||
version = "1.32";
|
||||
format = "setuptools";
|
||||
|
||||
src = fetchPypi {
|
||||
inherit pname version;
|
||||
sha256 = "b6ddfe6c3db30d81a96aaeceb6baf916094ffa23d7dd5fa2c13e13f8b6e600c2";
|
||||
disabled = pythonOlder "3.7";
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "stefankoegl";
|
||||
repo = "python-json-patch";
|
||||
rev = "v${version}";
|
||||
hash = "sha256-JMGBgYjnjHQ5JpzDwJcR2nVZfzmQ8ZZtcB0GsJ9Q4Jc=";
|
||||
};
|
||||
|
||||
# test files are missing
|
||||
doCheck = false;
|
||||
propagatedBuildInputs = [ jsonpointer ];
|
||||
propagatedBuildInputs = [
|
||||
jsonpointer
|
||||
];
|
||||
|
||||
meta = {
|
||||
checkInputs = [
|
||||
pytestCheckHook
|
||||
];
|
||||
|
||||
pythonImportsCheck = [
|
||||
"jsonpatch"
|
||||
];
|
||||
|
||||
pytestFlagsArray = [
|
||||
"tests.py"
|
||||
];
|
||||
|
||||
meta = with lib; {
|
||||
description = "Library to apply JSON Patches according to RFC 6902";
|
||||
homepage = "https://github.com/stefankoegl/python-json-patch";
|
||||
license = lib.licenses.bsd2; # "Modified BSD license, says pypi"
|
||||
license = licenses.bsd2; # "Modified BSD license, says pypi"
|
||||
maintainers = with maintainers; [ ];
|
||||
};
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue