mirror of
https://github.com/NixOS/nixpkgs.git
synced 2025-06-24 18:16:21 +03:00

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.
54 lines
1.1 KiB
Nix
54 lines
1.1 KiB
Nix
{ lib
|
|
, arrow
|
|
, buildPythonPackage
|
|
, fetchFromGitHub
|
|
, fetchpatch
|
|
, pythonOlder
|
|
, pytestCheckHook
|
|
}:
|
|
|
|
buildPythonPackage rec {
|
|
pname = "python-datemath";
|
|
version = "1.5.5";
|
|
format = "setuptools";
|
|
|
|
disabled = pythonOlder "3.8";
|
|
|
|
src = fetchFromGitHub {
|
|
owner = "nickmaccarthy";
|
|
repo = pname;
|
|
rev = "v${version}";
|
|
sha256 = "sha256-WVWGhyBguE1+KEMQu0N5QxO7IC4rPEJ/2L3VWUCQNi4=";
|
|
};
|
|
|
|
patches = [
|
|
(fetchpatch {
|
|
name = "remove-unittest2.patch";
|
|
url = "https://github.com/nickmaccarthy/python-datemath/commit/781daa0241ed327d5f211f3b62f553f3ee3d86e0.patch";
|
|
hash = "sha256-WD6fuDaSSNXgYWoaUexiWnofCzEZzercEUlqTvOUT5I=";
|
|
})
|
|
];
|
|
|
|
propagatedBuildInputs = [
|
|
arrow
|
|
];
|
|
|
|
nativeCheckInputs = [
|
|
pytestCheckHook
|
|
];
|
|
|
|
pytestFlagsArray = [
|
|
"tests.py"
|
|
];
|
|
|
|
pythonImportsCheck = [
|
|
"datemath"
|
|
];
|
|
|
|
meta = with lib; {
|
|
description = "Python module to emulate the date math used in SOLR and Elasticsearch";
|
|
homepage = "https://github.com/nickmaccarthy/python-datemath";
|
|
license = with licenses; [ asl20 ];
|
|
maintainers = with maintainers; [ fab ];
|
|
};
|
|
}
|