nixpkgs mirror (for testing) github.com/NixOS/nixpkgs
nix
at 22.05 96 lines 2.0 kB view raw
1{ lib 2, buildPythonApplication 3, fetchPypi 4, fetchpatch 5, pbr 6, cliff 7, jsonschema 8, testtools 9, paramiko 10, netaddr 11, oslo-concurrency 12, oslo-config 13, oslo-log 14, stestr 15, oslo-serialization 16, oslo-utils 17, fixtures 18, pyyaml 19, subunit 20, stevedore 21, prettytable 22, urllib3 23, debtcollector 24, hacking 25, oslotest 26, bash 27, python 28}: 29 30buildPythonApplication rec { 31 pname = "tempest"; 32 version = "29.2.0"; 33 34 src = fetchPypi { 35 inherit pname version; 36 sha256 = "0521d3042360c0fb469b16f99174a9abddbae8a2d2a81268cfc664f1ccfdd0f9"; 37 }; 38 39 patches = [ 40 # remove need for unittest2 41 (fetchpatch { 42 url = "https://github.com/openstack/tempest/commit/cd3745c27b7d8fcdaffc72b965a3d803d9ee12c2.patch"; 43 sha256 = "sha256-UwUmyFZokH66Xqfsj982MBHb0w7x6v4SAtXlqA5dpnk="; 44 }) 45 ]; 46 47 propagatedBuildInputs = [ 48 pbr 49 cliff 50 jsonschema 51 testtools 52 paramiko 53 netaddr 54 oslo-concurrency 55 oslo-config 56 oslo-log 57 stestr 58 oslo-serialization 59 oslo-utils 60 fixtures 61 pyyaml 62 subunit 63 stevedore 64 prettytable 65 urllib3 66 debtcollector 67 ]; 68 69 checkInputs = [ 70 stestr 71 hacking 72 oslotest 73 ]; 74 75 checkPhase = '' 76 # Tests expect these applications available as such. 77 mkdir -p bin 78 export PATH="$PWD/bin:$PATH" 79 printf '#!${bash}/bin/bash\nexec ${python.interpreter} -m tempest.cmd.main "$@"\n' > bin/tempest 80 printf '#!${bash}/bin/bash\nexec ${python.interpreter} -m tempest.cmd.subunit_describe_calls "$@"\n' > bin/subunit-describe-calls 81 chmod +x bin/* 82 83 stestr --test-path tempest/tests run -e <(echo " 84 tempest.tests.lib.cli.test_execute.TestExecute.test_execute_with_prefix 85 ") 86 ''; 87 88 pythonImportsCheck = [ "tempest" ]; 89 90 meta = with lib; { 91 description = "An OpenStack integration test suite that runs against live OpenStack cluster and validates an OpenStack deployment"; 92 homepage = "https://github.com/openstack/tempest"; 93 license = licenses.asl20; 94 maintainers = teams.openstack.members; 95 }; 96}