python313Packages.django-scheduler: refactor

Use pep517 builder and pytest-django for tests.
This commit is contained in:
Martin Weinelt
2025-05-24 02:30:17 +02:00
parent 8c89e993c3
commit 9a19bed33f
@@ -4,16 +4,18 @@
django,
fetchFromGitHub,
icalendar,
python,
pytestCheckHook,
pytest-django,
python-dateutil,
pythonOlder,
pytz,
setuptools,
}:
buildPythonPackage rec {
pname = "django-scheduler";
version = "0.10.1";
format = "setuptools";
pyproject = true;
disabled = pythonOlder "3.7";
@@ -24,17 +26,22 @@ buildPythonPackage rec {
hash = "sha256-dY2TPo15RRWrv7LheUNJSQl4d/HeptSMM/wQirRSI5w=";
};
propagatedBuildInputs = [
build-system = [ setuptools ];
dependencies = [
django
python-dateutil
pytz
icalendar
];
checkPhase = ''
runHook preCheck
${python.interpreter} -m django check --settings=tests.settings
runHook postCheck
nativeCheckInputs = [
pytestCheckHook
pytest-django
];
preCheck = ''
export DJANGO_SETTINGS_MODULE=tests.settings
'';
pythonImportsCheck = [ "schedule" ];