2021-02-05 17:12:51 +00:00
|
|
|
{ lib
|
2020-04-24 23:36:52 +00:00
|
|
|
, buildPythonPackage
|
|
|
|
, fetchPypi
|
|
|
|
, isPy27
|
|
|
|
, webob
|
|
|
|
, six
|
|
|
|
, beautifulsoup4
|
|
|
|
, waitress
|
|
|
|
, pyquery
|
|
|
|
, wsgiproxy2
|
2021-10-08 15:17:17 +00:00
|
|
|
, pastedeploy
|
2022-02-10 20:34:41 +00:00
|
|
|
, pytestCheckHook
|
2020-04-24 23:36:52 +00:00
|
|
|
}:
|
|
|
|
|
|
|
|
buildPythonPackage rec {
|
2022-02-10 20:34:41 +00:00
|
|
|
version = "3.0.0";
|
2020-04-24 23:36:52 +00:00
|
|
|
pname = "webtest";
|
|
|
|
disabled = isPy27; # paste.deploy is not longer a valid import
|
|
|
|
|
|
|
|
src = fetchPypi {
|
|
|
|
pname = "WebTest";
|
|
|
|
inherit version;
|
2022-02-10 20:34:41 +00:00
|
|
|
sha256 = "54bd969725838d9861a9fa27f8d971f79d275d94ae255f5c501f53bb6d9929eb";
|
2020-04-24 23:36:52 +00:00
|
|
|
};
|
|
|
|
|
2021-10-08 15:17:17 +00:00
|
|
|
postPatch = ''
|
2020-04-24 23:36:52 +00:00
|
|
|
substituteInPlace setup.py --replace "nose<1.3.0" "nose"
|
|
|
|
'';
|
|
|
|
|
2021-08-22 07:53:02 +00:00
|
|
|
propagatedBuildInputs = [
|
|
|
|
webob
|
|
|
|
six
|
|
|
|
beautifulsoup4
|
|
|
|
waitress
|
|
|
|
];
|
|
|
|
|
|
|
|
checkInputs = [
|
2022-02-10 20:34:41 +00:00
|
|
|
pytestCheckHook
|
2021-10-08 15:17:17 +00:00
|
|
|
pastedeploy
|
2021-08-22 07:53:02 +00:00
|
|
|
wsgiproxy2
|
|
|
|
pyquery
|
|
|
|
];
|
2020-04-24 23:36:52 +00:00
|
|
|
|
|
|
|
# Some of the tests use localhost networking.
|
|
|
|
__darwinAllowLocalNetworking = true;
|
|
|
|
|
2021-08-22 07:53:02 +00:00
|
|
|
pythonImportsCheck = [ "webtest" ];
|
|
|
|
|
2021-01-15 22:18:51 +00:00
|
|
|
meta = with lib; {
|
2020-04-24 23:36:52 +00:00
|
|
|
description = "Helper to test WSGI applications";
|
|
|
|
homepage = "https://webtest.readthedocs.org/en/latest/";
|
|
|
|
license = licenses.mit;
|
2021-08-22 07:53:02 +00:00
|
|
|
maintainers = with maintainers; [ ];
|
2020-04-24 23:36:52 +00:00
|
|
|
};
|
|
|
|
}
|