1{ lib
2, buildPythonApplication
3, fetchPypi
4, pbr
5, cliff
6, jsonschema
7, testtools
8, paramiko
9, netaddr
10, oslo-concurrency
11, oslo-config
12, oslo-log
13, stestr
14, oslo-serialization
15, oslo-utils
16, fixtures
17, pyyaml
18, subunit
19, stevedore
20, prettytable
21, urllib3
22, debtcollector
23, unittest2
24, hacking
25, oslotest
26, bash
27, python3
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 propagatedBuildInputs = [
40 pbr
41 cliff
42 jsonschema
43 testtools
44 paramiko
45 netaddr
46 oslo-concurrency
47 oslo-config
48 oslo-log
49 stestr
50 oslo-serialization
51 oslo-utils
52 fixtures
53 pyyaml
54 subunit
55 stevedore
56 prettytable
57 urllib3
58 debtcollector
59 unittest2
60 ];
61
62 checkInputs = [
63 stestr
64 hacking
65 oslotest
66 ];
67
68 checkPhase = ''
69 # Tests expect these applications available as such.
70 mkdir -p bin
71 export PATH="$PWD/bin:$PATH"
72 printf '#!${bash}/bin/bash\nexec ${python3.interpreter} -m tempest.cmd.main "$@"\n' > bin/tempest
73 printf '#!${bash}/bin/bash\nexec ${python3.interpreter} -m tempest.cmd.subunit_describe_calls "$@"\n' > bin/subunit-describe-calls
74 chmod +x bin/*
75
76 stestr --test-path tempest/tests run -e <(echo "
77 tempest.tests.lib.cli.test_execute.TestExecute.test_execute_with_prefix
78 ")
79 '';
80
81 pythonImportsCheck = [ "tempest" ];
82
83 meta = with lib; {
84 description = "An OpenStack integration test suite that runs against live OpenStack cluster and validates an OpenStack deployment";
85 homepage = "https://github.com/openstack/tempest";
86 license = licenses.asl20;
87 maintainers = teams.openstack.members;
88 };
89}