Move additional RBAC tests into test_server_misc_policy_actions_rbac.py

Bug #1699415 reported by Felipe Monteiro
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Patrole
Fix Released
High
Felipe Monteiro

Bug Description

Move additional RBAC tests into test_server_misc_policy_actions_rbac.py to further increase gate stability.

The number of calls to create_test_server() should be minimized for RBAC testing because we don't do too much modification to the resources that are created -- only what's necessary to trigger the API action corresponding to the RBAC policy under test. Further, minimizing such calls reduces the risk of spinning up too many servers concurrently in our gates: the source of various gate failures as limited resources lead to server faults being raised.

To that end, the following tests can be migrated to test_server_misc_policy_actions_rbac.py:

- test_simple_tenant_usage_show (although the list test doesn't need to be added so maybe it's better to not split them up)
- tests in test_suspend_server_rbac.py
- tests in test_lock_server_rbac.py
- tests in test_server_virtual_interfaces_rbac.py
- tests in test_admin_password_rbac.py
- one test in test_ips_rbac.py (although that would break things up)
- any others that are applicable

Felipe Monteiro (fm577c)
Changed in patrole:
importance: Undecided → Medium
Felipe Monteiro (fm577c)
Changed in patrole:
importance: Medium → High
Felipe Monteiro (fm577c)
Changed in patrole:
assignee: nobody → Felipe Monteiro (fm577c)
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to patrole (master)

Fix proposed to branch: master
Review: https://review.openstack.org/476956

Changed in patrole:
status: New → In Progress
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to patrole (master)

Reviewed: https://review.openstack.org/476956
Committed: https://git.openstack.org/cgit/openstack/patrole/commit/?id=a662f824fea8fe8347391371ab468b1561637bf3
Submitter: Jenkins
Branch: master

commit a662f824fea8fe8347391371ab468b1561637bf3
Author: Felipe Monteiro <email address hidden>
Date: Fri Jun 23 16:39:07 2017 +0100

    Minimize number of servers created for more tests

    Move additional RBAC tests into test_server_misc_policy_actions_rbac.py
    to further increase gate stability and decrease gate run time.

    The number of calls to create_test_server() should be minimized
    for RBAC testing because we don't do too much modification to the
    resources that are created -- only what's necessary to trigger the
    API action corresponding to the RBAC policy under test. Further,
    minimizing such calls reduces the risk of spinning up too many servers
    concurrently in our gates: the source of various gate failures as
    limited resources lead to server faults being raised.

    To that end, the following tests can be migrated to
    test_server_misc_policy_actions_rbac.py:

      - test_admin_password_rbac
      - test_lock_server_rbac
      - test_suspend_server_rbac

    Additional migrations will be made in follow-up patches.

    Change-Id: I7cf80d39b770afeb02d666266411fa2a91601eb9
    Partial-Bug: #1699415

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to patrole (master)

Fix proposed to branch: master
Review: https://review.openstack.org/480650

Revision history for this message
OpenStack Infra (hudson-openstack) wrote :

Fix proposed to branch: master
Review: https://review.openstack.org/481404

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Related fix proposed to patrole (master)

Related fix proposed to branch: master
Review: https://review.openstack.org/481410

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to patrole (master)

Reviewed: https://review.openstack.org/481404
Committed: https://git.openstack.org/cgit/openstack/patrole/commit/?id=4047a19265e939eb9c9d6308acf2c879762e9b6d
Submitter: Jenkins
Branch: master

commit 4047a19265e939eb9c9d6308acf2c879762e9b6d
Author: Felipe Monteiro <email address hidden>
Date: Fri Jul 7 04:56:36 2017 +0100

    Move tenant usage tests into misc policy actions file

    Move tenant usage tests into test_server_misc_policy_actions_rbac.py
    to further increase gate stability and decrease gate run time.

    The number of calls to create_test_server() should be minimized
    for RBAC testing because we don't do too much modification to the
    resources that are created -- only what's necessary to trigger the
    API action corresponding to the RBAC policy under test. Further,
    minimizing such calls reduces the risk of spinning up too many servers
    concurrently in our gates: the source of various gate failures as
    limited resources lead to server faults being raised.

    Change-Id: Ib104c08a5fa1708a829e5f91a587df6ba9c08ee0
    Partial-Bug: #1699415

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Related fix merged to patrole (master)

Reviewed: https://review.openstack.org/481410
Committed: https://git.openstack.org/cgit/openstack/patrole/commit/?id=a7d9425c26ae4bf32e1b0d1363f67866b14d30f0
Submitter: Jenkins
Branch: master

commit a7d9425c26ae4bf32e1b0d1363f67866b14d30f0
Author: Felipe Monteiro <email address hidden>
Date: Fri Jul 7 04:48:30 2017 +0100

    Group together tests that create server and require network resources

    Group together tests that create a server and require network resources
    so as to reduce overhead with creating a server and improving gate
    stability. While these tests could also be grouped with
    test_server_misc_policy_actions.py, those tests don't require network
    resources, so it makes sense to separate out the network resource tests
    into a separate class.

    This commit groups together the tests from the following files:

      * test_attach_interfaces_rbac
      * test_ips_rbac
      * test_multinic_rbac

    into a shared class (MiscPolicyActionsNetworkRbacTest) inside
    test_server_misc_policy_actions_rbac.py.

    Closes-Bug: #1699421
    Related-Bug: #1699415
    Change-Id: I01c5e635028a6696331b1dc1401e274543db2716

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to patrole (master)

Fix proposed to branch: master
Review: https://review.openstack.org/484215

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to patrole (master)

Reviewed: https://review.openstack.org/484215
Committed: https://git.openstack.org/cgit/openstack/patrole/commit/?id=6c068fcbbed3d148b4f79464bdafac08650e42ab
Submitter: Jenkins
Branch: master

commit 6c068fcbbed3d148b4f79464bdafac08650e42ab
Author: Felipe Monteiro <email address hidden>
Date: Mon Jul 17 00:13:21 2017 +0100

    Move config drive tests into misc policy actions file

    This commit does 3 things:
      1a) Corrects the "config_drive" tests by aligning the
          tests with the nova policy documentation [0] which
          states that "config_drive" is to added the response
          body of showing a server or listing servers with details
          if policy enforcement passes.
      1b) Consequently, 2 tests are added: 1 for show and 1 for
          list with details.
      2) Moves both tests into the misc policy actions file to
         increase gate stability and decrease gate run time.

    The number of calls to create_test_server() should be minimized
    for RBAC testing because we don't do too much modification to the
    resources that are created -- only what's necessary to trigger the
    API action corresponding to the RBAC policy under test. Further,
    minimizing such calls reduces the risk of spinning up too many servers
    concurrently in our gates: the source of various gate failures as
    limited resources lead to server faults being raised.

    [0] https://github.com/openstack/nova/blob/master/nova/policies/config_drive.py

    Change-Id: If54fce795c2289b097b617cad7268dc9a3d9cf1c
    Partial-Bug: #1699415

Revision history for this message
OpenStack Infra (hudson-openstack) wrote :

Reviewed: https://review.openstack.org/480650
Committed: https://git.openstack.org/cgit/openstack/patrole/commit/?id=d98273152abbcdefeb40a8712af270c3f1e5d6f3
Submitter: Jenkins
Branch: master

commit d98273152abbcdefeb40a8712af270c3f1e5d6f3
Author: Felipe Monteiro <email address hidden>
Date: Wed Jul 5 16:33:03 2017 +0100

    Move virtual interfaces test into misc policy actions file

    Move test_list_virtual_interfaces into
    test_server_misc_policy_actions_rbac.py to further increase gate
    stability and decrease gate run time.

    The number of calls to create_test_server() should be minimized
    for RBAC testing because we don't do too much modification to the
    resources that are created -- only what's necessary to trigger the
    API action corresponding to the RBAC policy under test. Further,
    minimizing such calls reduces the risk of spinning up too many servers
    concurrently in our gates: the source of various gate failures as
    limited resources lead to server faults being raised.

    Change-Id: I1ff0c14e741c8907f2f23a4dd63705713f06d337
    Partial-Bug: #1699415

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to patrole (master)

Fix proposed to branch: master
Review: https://review.openstack.org/484533

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to patrole (master)

Reviewed: https://review.openstack.org/484533
Committed: https://git.openstack.org/cgit/openstack/patrole/commit/?id=10fdf98c128fc890863c34872e1681a61a8b9cfa
Submitter: Jenkins
Branch: master

commit 10fdf98c128fc890863c34872e1681a61a8b9cfa
Author: Felipe Monteiro <email address hidden>
Date: Tue Jul 18 04:56:29 2017 +0100

    Move instance actions test into misc policy actions file

    Move instance actions tests into
    test_server_misc_policy_actions_rbac.py to further increase gate
    stability and decrease gate run time.

    The number of calls to create_test_server() should be minimized
    for RBAC testing because we don't do too much modification to the
    resources that are created -- only what's necessary to trigger the
    API action corresponding to the RBAC policy under test. Further,
    minimizing such calls reduces the risk of spinning up too many servers
    concurrently in our gates: the source of various gate failures as
    limited resources lead to server faults being raised.

    Change-Id: Ie01db6f58229f843684d9b4904defa6ed85b5f17
    Partial-Bug: #1699415

Felipe Monteiro (fm577c)
Changed in patrole:
status: In Progress → Fix Committed
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.