1{ lib
2, buildPythonPackage
3, pythonOlder
4, fetchFromGitHub
5, poetry-core
6, aiohttp
7, pytest
8, pytest-asyncio
9, pytestCheckHook
10}:
11
12buildPythonPackage rec {
13 pname = "pytest-mockservers";
14 version = "0.6.0";
15 format = "pyproject";
16 disabled = pythonOlder "3.6";
17
18 src = fetchFromGitHub {
19 owner = "Gr1N";
20 repo = pname;
21 rev = version;
22 sha256 = "0xql0fnw7m2zn103601gqbpyd761kzvgjj2iz9hjsv56nr4z1g9i";
23 };
24
25 postPatch = ''
26 substituteInPlace pyproject.toml \
27 --replace "poetry.masonry.api" "poetry.core.masonry.api"
28 '';
29
30 nativeBuildInputs = [
31 poetry-core
32 ];
33
34 buildInputs = [
35 pytest
36 ];
37
38 propagatedBuildInputs = [
39 aiohttp
40 pytest-asyncio
41 ];
42
43 nativeCheckInputs = [
44 pytestCheckHook
45 ];
46
47 pythonImportsCheck = [
48 "pytest_mockservers"
49 ];
50
51 meta = with lib; {
52 description = "A set of fixtures to test your requests to HTTP/UDP servers";
53 homepage = "https://github.com/Gr1N/pytest-mockservers";
54 license = licenses.mit;
55 maintainers = with maintainers; [ fab ];
56 };
57}