2024-06-05 15:53:02 +00:00
|
|
|
{
|
|
|
|
lib,
|
|
|
|
buildPythonPackage,
|
|
|
|
fetchFromGitHub,
|
|
|
|
httpbin,
|
|
|
|
pytest,
|
|
|
|
pytestCheckHook,
|
|
|
|
pythonOlder,
|
|
|
|
requests,
|
2024-06-20 14:57:18 +00:00
|
|
|
setuptools,
|
2020-04-24 23:36:52 +00:00
|
|
|
}:
|
|
|
|
|
|
|
|
buildPythonPackage rec {
|
|
|
|
pname = "pytest-httpbin";
|
2023-11-16 04:20:00 +00:00
|
|
|
version = "2.0.0";
|
2024-06-20 14:57:18 +00:00
|
|
|
pyproject = true;
|
2022-06-26 10:26:21 +00:00
|
|
|
|
|
|
|
disabled = pythonOlder "3.7";
|
2020-04-24 23:36:52 +00:00
|
|
|
|
2022-02-10 20:34:41 +00:00
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "kevin1024";
|
|
|
|
repo = "pytest-httpbin";
|
2023-11-16 04:20:00 +00:00
|
|
|
rev = "refs/tags/v${version}";
|
|
|
|
hash = "sha256-tq9nz2na94HkLACt7xB1MUanh9/JOoe2vyEm5sAq0/4=";
|
2020-04-24 23:36:52 +00:00
|
|
|
};
|
|
|
|
|
2024-06-20 14:57:18 +00:00
|
|
|
build-system = [ setuptools ];
|
|
|
|
|
2024-06-05 15:53:02 +00:00
|
|
|
buildInputs = [ pytest ];
|
2020-04-24 23:36:52 +00:00
|
|
|
|
2024-06-20 14:57:18 +00:00
|
|
|
propagatedBuildInputs = [ httpbin ];
|
2020-04-24 23:36:52 +00:00
|
|
|
|
2023-02-02 18:25:31 +00:00
|
|
|
nativeCheckInputs = [
|
2022-02-10 20:34:41 +00:00
|
|
|
pytestCheckHook
|
|
|
|
requests
|
|
|
|
];
|
2020-04-24 23:36:52 +00:00
|
|
|
|
2023-11-16 04:20:00 +00:00
|
|
|
disabledTests = [
|
|
|
|
# incompatible with flask 2.3
|
|
|
|
"test_redirect_location_is_https_for_secure_server"
|
2024-06-20 14:57:18 +00:00
|
|
|
# Timeout on Hydra
|
|
|
|
"test_dont_crash_on_handshake_timeout"
|
2023-11-16 04:20:00 +00:00
|
|
|
];
|
|
|
|
|
2023-04-12 12:48:02 +00:00
|
|
|
__darwinAllowLocalNetworking = true;
|
|
|
|
|
2024-06-05 15:53:02 +00:00
|
|
|
pythonImportsCheck = [ "pytest_httpbin" ];
|
2020-04-24 23:36:52 +00:00
|
|
|
|
2022-02-10 20:34:41 +00:00
|
|
|
meta = with lib; {
|
|
|
|
description = "Test your HTTP library against a local copy of httpbin.org";
|
2020-04-24 23:36:52 +00:00
|
|
|
homepage = "https://github.com/kevin1024/pytest-httpbin";
|
2024-06-20 14:57:18 +00:00
|
|
|
changelog = "https://github.com/kevin1024/pytest-httpbin/releases/tag/v${version}";
|
2022-02-10 20:34:41 +00:00
|
|
|
license = licenses.mit;
|
|
|
|
maintainers = with maintainers; [ ];
|
2020-04-24 23:36:52 +00:00
|
|
|
};
|
|
|
|
}
|