Clone of https://github.com/NixOS/nixpkgs.git (to stress-test knotserver)
at 19.09 39 lines 1.1 kB view raw
1{ lib, buildPythonPackage, fetchFromGitHub 2, elementpath 3, pytest 4}: 5 6buildPythonPackage rec { 7 version = "1.0.13"; 8 pname = "xmlschema"; 9 10 src = fetchFromGitHub { 11 owner = "sissaschool"; 12 repo = "xmlschema"; 13 rev = "v${version}"; 14 sha256 = "182439gqhlxhr9rdi9ak33z4ffy1w9syhykkckkl6mq050c80qdr"; 15 }; 16 17 propagatedBuildInputs = [ elementpath ]; 18 19 checkInputs = [ pytest ]; 20 21 # Ignore broken fixtures, and tests for files which don't exist. 22 # For darwin, we need to explicity say we can't reach network 23 checkPhase = '' 24 substituteInPlace xmlschema/tests/__init__.py \ 25 --replace "SKIP_REMOTE_TESTS = " "SKIP_REMOTE_TESTS = True #" 26 pytest . \ 27 --ignore=xmlschema/tests/test_factory.py \ 28 --ignore=xmlschema/tests/test_validators.py \ 29 --ignore=xmlschema/tests/test_schemas.py \ 30 -k 'not element_tree_import_script' 31 ''; 32 33 meta = with lib; { 34 description = "XML Schema validator and data conversion library for Python"; 35 homepage = "https://github.com/sissaschool/xmlschema"; 36 license = licenses.mit; 37 maintainers = with maintainers; [ jonringer ]; 38 }; 39}