blob: b7762e12175c168f0c6188d1f8ac02ee0f3c3e45 (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
|
{ lib
, buildPythonPackage
, callPackage
, fetchFromGitHub
, pytest
, pythonOlder
, setuptools-scm
}:
buildPythonPackage rec {
pname = "pytest-asyncio";
version = "0.23.6"; # N.B.: when updating, tests bleak and aioesphomeapi tests
pyproject = true;
disabled = pythonOlder "3.8";
src = fetchFromGitHub {
owner = "pytest-dev";
repo = "pytest-asyncio";
rev = "refs/tags/v${version}";
hash = "sha256-+kyKcVzW05kqtLeC81rk3fJpOtyW3xSYshgl5gqIddE=";
};
outputs = [
"out"
"testout"
];
nativeBuildInputs = [
setuptools-scm
];
buildInputs = [
pytest
];
postInstall = ''
mkdir $testout
cp -R tests $testout/tests
'';
doCheck = false;
passthru.tests.pytest = callPackage ./tests.nix {};
pythonImportsCheck = [
"pytest_asyncio"
];
meta = with lib; {
description = "Library for testing asyncio code with pytest";
homepage = "https://github.com/pytest-dev/pytest-asyncio";
changelog = "https://github.com/pytest-dev/pytest-asyncio/blob/v${version}/docs/source/reference/changelog.rst";
license = licenses.asl20;
maintainers = with maintainers; [ dotlambda ];
};
}
|