2018-07-23 20:26:04 +00:00
|
|
|
{ lib, buildPythonPackage, fetchPypi
|
2019-07-21 09:21:00 +00:00
|
|
|
, setuptools_scm, pytest, freezegun, backports_unittest-mock
|
2020-06-22 22:33:46 +00:00
|
|
|
, pytest-black, pytestcov, pytest-flake8
|
2018-07-23 20:26:04 +00:00
|
|
|
, six, pytz, jaraco_functools }:
|
2017-08-31 11:16:17 +00:00
|
|
|
|
|
|
|
buildPythonPackage rec {
|
2017-09-05 09:16:41 +00:00
|
|
|
pname = "tempora";
|
2020-06-06 06:47:33 +00:00
|
|
|
version = "3.0.0";
|
2017-08-31 11:16:17 +00:00
|
|
|
|
|
|
|
src = fetchPypi {
|
|
|
|
inherit pname version;
|
2020-06-06 06:47:33 +00:00
|
|
|
sha256 = "e370d822cf48f5356aab0734ea45807250f5120e291c76712a1d766b49ae34f8";
|
2017-08-31 11:16:17 +00:00
|
|
|
};
|
|
|
|
|
2020-06-22 22:33:46 +00:00
|
|
|
nativeBuildInputs = [ setuptools_scm ];
|
2017-08-31 11:16:17 +00:00
|
|
|
|
2018-07-23 20:26:04 +00:00
|
|
|
propagatedBuildInputs = [ six pytz jaraco_functools ];
|
|
|
|
|
2020-06-22 22:33:46 +00:00
|
|
|
checkInputs = [ pytest pytest-flake8 pytest-black pytestcov freezegun backports_unittest-mock ];
|
2019-07-21 09:21:00 +00:00
|
|
|
|
2020-06-22 22:33:46 +00:00
|
|
|
# missing pytest-freezegun package
|
2019-07-21 09:21:00 +00:00
|
|
|
checkPhase = ''
|
2020-06-22 22:33:46 +00:00
|
|
|
pytest -k 'not get_nearest_year_for_day'
|
2019-07-21 09:21:00 +00:00
|
|
|
'';
|
|
|
|
|
2018-07-23 20:26:04 +00:00
|
|
|
meta = with lib; {
|
|
|
|
description = "Objects and routines pertaining to date and time";
|
2020-04-01 01:11:51 +00:00
|
|
|
homepage = "https://github.com/jaraco/tempora";
|
2018-07-23 20:26:04 +00:00
|
|
|
license = licenses.mit;
|
|
|
|
};
|
2017-08-31 11:16:17 +00:00
|
|
|
}
|