2024-06-05 15:53:02 +00:00
|
|
|
{
|
|
|
|
lib,
|
|
|
|
buildPythonPackage,
|
|
|
|
fetchPypi,
|
|
|
|
setuptools,
|
|
|
|
zope-interface,
|
|
|
|
zope-schema,
|
|
|
|
zope-cachedescriptors,
|
|
|
|
pytz,
|
|
|
|
webtest,
|
|
|
|
beautifulsoup4,
|
|
|
|
soupsieve,
|
|
|
|
wsgiproxy2,
|
|
|
|
six,
|
|
|
|
mock,
|
|
|
|
zope-testing,
|
|
|
|
zope-testrunner,
|
|
|
|
python,
|
2022-07-14 12:49:19 +00:00
|
|
|
}:
|
|
|
|
|
|
|
|
buildPythonPackage rec {
|
|
|
|
pname = "zope-testbrowser";
|
2023-11-16 04:20:00 +00:00
|
|
|
version = "6.0";
|
2022-07-14 12:49:19 +00:00
|
|
|
|
|
|
|
format = "setuptools";
|
|
|
|
|
|
|
|
src = fetchPypi {
|
|
|
|
pname = "zope.testbrowser";
|
|
|
|
inherit version;
|
2023-11-16 04:20:00 +00:00
|
|
|
sha256 = "sha256-RLd6XpA3q+3DZHai6j3H6XTWE85Sk913zAL4iO4x+ho=";
|
2022-07-14 12:49:19 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
postPatch = ''
|
|
|
|
# remove test that requires network access
|
|
|
|
substituteInPlace src/zope/testbrowser/tests/test_doctests.py \
|
|
|
|
--replace "suite.addTests(wire)" ""
|
|
|
|
'';
|
|
|
|
|
|
|
|
propagatedBuildInputs = [
|
|
|
|
setuptools
|
2024-01-13 08:15:51 +00:00
|
|
|
zope-interface
|
|
|
|
zope-schema
|
2022-07-14 12:49:19 +00:00
|
|
|
zope-cachedescriptors
|
|
|
|
pytz
|
|
|
|
webtest
|
|
|
|
beautifulsoup4
|
|
|
|
soupsieve
|
|
|
|
wsgiproxy2
|
|
|
|
six
|
|
|
|
];
|
|
|
|
|
2023-02-02 18:25:31 +00:00
|
|
|
nativeCheckInputs = [
|
2022-07-14 12:49:19 +00:00
|
|
|
mock
|
2024-01-02 11:29:13 +00:00
|
|
|
zope-testing
|
2024-01-13 08:15:51 +00:00
|
|
|
zope-testrunner
|
2022-07-14 12:49:19 +00:00
|
|
|
];
|
|
|
|
|
|
|
|
checkPhase = ''
|
|
|
|
${python.interpreter} -m zope.testrunner --test-path=src
|
|
|
|
'';
|
|
|
|
|
|
|
|
pythonImportsCheck = [
|
|
|
|
"zope.testbrowser"
|
|
|
|
"zope.testbrowser.browser"
|
|
|
|
"zope.testbrowser.interfaces"
|
|
|
|
"zope.testbrowser.testing"
|
|
|
|
"zope.testbrowser.wsgi"
|
|
|
|
];
|
|
|
|
|
|
|
|
meta = {
|
|
|
|
description = "Programmable browser for functional black-box tests";
|
|
|
|
homepage = "https://github.com/zopefoundation/zope.testbrowser";
|
|
|
|
license = lib.licenses.zpl21;
|
|
|
|
maintainers = with lib.maintainers; [ dotlambda ];
|
|
|
|
};
|
|
|
|
}
|