nixpkgs mirror (for testing) github.com/NixOS/nixpkgs
nix
at python-updates 82 lines 1.7 kB view raw
1{ 2 lib, 3 buildPythonPackage, 4 fetchFromGitHub, 5 setuptools, 6 zope-interface, 7 zope-schema, 8 zope-cachedescriptors, 9 pytz, 10 webtest, 11 beautifulsoup4, 12 soupsieve, 13 wsgiproxy2, 14 legacy-cgi, 15 mock, 16 zope-testing, 17 zope-testrunner, 18 python, 19}: 20 21buildPythonPackage rec { 22 pname = "zope-testbrowser"; 23 version = "8.0"; 24 pyproject = true; 25 26 src = fetchFromGitHub { 27 owner = "zopefoundation"; 28 repo = "zope.testbrowser"; 29 tag = version; 30 hash = "sha256-CcNlK7EKYng0GKYTZ2U2slkyQ9wTqwzOXGHt9S5p3L0="; 31 }; 32 33 postPatch = '' 34 substituteInPlace pyproject.toml \ 35 --replace-fail "setuptools ==" "setuptools >=" 36 37 # remove test that requires network access 38 substituteInPlace src/zope/testbrowser/tests/test_doctests.py \ 39 --replace-fail "suite.addTests(wire)" "" 40 ''; 41 42 build-system = [ setuptools ]; 43 44 dependencies = [ 45 setuptools 46 zope-interface 47 zope-schema 48 zope-cachedescriptors 49 pytz 50 webtest 51 beautifulsoup4 52 soupsieve 53 wsgiproxy2 54 legacy-cgi 55 ]; 56 57 nativeCheckInputs = [ 58 mock 59 zope-testing 60 zope-testrunner 61 ]; 62 63 checkPhase = '' 64 ${python.interpreter} -m zope.testrunner --test-path=src 65 ''; 66 67 pythonImportsCheck = [ 68 "zope.testbrowser" 69 "zope.testbrowser.browser" 70 "zope.testbrowser.interfaces" 71 "zope.testbrowser.testing" 72 "zope.testbrowser.wsgi" 73 ]; 74 75 meta = { 76 changelog = "https://github.com/zopefoundation/zope.testbrowser/blob/${src.rev}/CHANGES.rst"; 77 description = "Programmable browser for functional black-box tests"; 78 homepage = "https://github.com/zopefoundation/zope.testbrowser"; 79 license = lib.licenses.zpl21; 80 maintainers = with lib.maintainers; [ dotlambda ]; 81 }; 82}