1{ lib, buildPythonPackage, fetchFromGitHub, flit-core }:
2
3buildPythonPackage rec {
4 pname = "pytest-celery";
5 version = "0.1.0";
6
7 format = "pyproject";
8
9 src = fetchFromGitHub {
10 owner = "celery";
11 repo = "pytest-celery";
12 rev = "v${version}";
13 hash = "sha256-vzWwkOS3BLOInaFDk+PegvEmC88ZZ1sG1CmHwhn7r9w=";
14 };
15
16 postPatch = ''
17 # avoid infinite recursion with celery
18 substituteInPlace pyproject.toml \
19 --replace '"celery >= 4.4.0"' ""
20 '';
21
22 nativeBuildInputs = [
23 flit-core
24 ];
25
26 # This package has nothing to test or import.
27 doCheck = false;
28
29 meta = with lib; {
30 description = "Pytest plugin to enable celery.contrib.pytest";
31 homepage = "https://github.com/celery/pytest-celery";
32 license = licenses.mit;
33 maintainers = [ ];
34 };
35}