Fixes instance actions compute rbac test failing for Member role.

Currently, test_get_instance_action is failing with an over
permission error with Member role [0]. Even though
the policy action os-instance-actions:events has rule
admin_api (is_admin:True) [1], Nova still allows the
API call (servers_client.show_instance_actions) to be
performed.

This can be seen in the nova controller code [2]:
InstanceActionsController.show enforces
os_compute_api:os-instance-actions (which allows
Member to get some instance action info), then
tries to do os_compute_api:os-instance-actions:events,
but fails, which is not a fatal error; instead,
the response body is not populated with "events"
info.

This patch adds a check for "events" in the response
body to the test: if "events" is not found,
then an RbacActionFailed exception is raised.

[0] http://logs.openstack.org/99/446799/1/check/gate-tempest-dsvm-patrole-member-ubuntu-xenial-nv/6072e55/console.html
[1] https://github.com/openstack/nova/blob/master/nova/policies/instance_actions.py
[2] https://github.com/openstack/nova/blob/4f91ed3a547965ed96a22520edcfb783e7936e95/nova/api/openstack/compute/instance_actions.py

Change-Id: Iecae5aafaa51eb28f06d34556027be8b0bb46708
Partial-Bug: #1670553
1 file changed