blob: c2fc6d326e55b3e1011ea76825c70e5fb5d6acda [file] [log] [blame]
Felipe Monteiro7bc35dc2017-04-19 21:11:46 +01001..
2
DavidPurcell663aedf2017-01-03 10:01:14 -05003========
4Usage
5========
6
Felipe Monteiro7bc35dc2017-04-19 21:11:46 +01007Running Patrole Tests in Tempest
8================================
DavidPurcell663aedf2017-01-03 10:01:14 -05009
Felipe Monteiro7bc35dc2017-04-19 21:11:46 +010010If Patrole is installed correctly, then the API tests can be executed
11from inside the tempest root directory as follows: ::
DavidPurcell663aedf2017-01-03 10:01:14 -050012
Felipe Monteiro7bc35dc2017-04-19 21:11:46 +010013 tox -eall-plugin -- patrole_tempest_plugin.tests.api
14
15To execute patrole tests for a specific module, run: ::
16
17 tox -eall-plugin -- patrole_tempest_plugin.tests.api.compute
18
19To change the role that the patrole tests are being run as, edit
20``rbac_test_role`` in the ``rbac`` section of tempest.conf: ::
21
22 [rbac]
23 rbac_test_role = Member
24 ...
25
26.. note::
27
28 The ``rbac_test_role`` is service-specific. Member, for example,
29 is an arbitrary role, but by convention is used to designate the default
30 non-admin role in the system. Most patrole tests should be run with
31 **admin** and **Member** roles. However, some services, like Heat, take
32 advantage of a role called **heat_stack_user**, as it appears frequently
33 in Heat's policy.json.
34
35For more information about the Member role,
36please see: `<https://ask.openstack.org/en/question/4759/member-vs-_member_/>`__.