-
Notifications
You must be signed in to change notification settings - Fork 165
[WIP] Adding test coverage #9085
base: master
Are you sure you want to change the base?
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -6,39 +6,6 @@ | |
from cfme.cloud.provider.openstack import OpenStackProvider | ||
|
||
|
||
@pytest.mark.manual | ||
@pytest.mark.provider([OpenStackProvider]) | ||
@test_requirements.snapshot | ||
@pytest.mark.tier(1) | ||
def test_osp_snapshot_buttons(): | ||
""" | ||
Test new OSP snapshot button and make sure Snapshot link is removed from Instance Details | ||
page. | ||
|
||
Polarion: | ||
assignee: apagac | ||
casecomponent: Cloud | ||
caseimportance: medium | ||
initialEstimate: 1/4h | ||
startsin: 5.10 | ||
setup: | ||
1. Have OSP provider added and test instance created | ||
testSteps: | ||
1. Navigate to test instance | ||
2. Make sure the snapshot button is displayed in the top menu | ||
3. Try snapshot crud | ||
4. Navigate to instance summary screen; Check if the original Snapshot link is present | ||
expectedResults: | ||
1. Test instance summary page displayed | ||
2. Snapshot button displayed | ||
3. Snapshot created; Snapshot deleted | ||
4. Snapshot link is not displayed | ||
Bugzilla: | ||
1690954 | ||
""" | ||
pass | ||
|
||
|
||
@pytest.mark.manual | ||
@pytest.mark.provider([OpenStackProvider]) | ||
@test_requirements.snapshot | ||
|
@@ -165,3 +132,30 @@ def test_snapshot_cloud_tenant(): | |
1685300 | ||
""" | ||
pass | ||
|
||
|
||
@pytest.mark.manual | ||
@pytest.mark.provider([OpenStackProvider]) | ||
@test_requirements.snapshot | ||
@pytest.mark.tier(2) | ||
def test_snapshot_description_mandatory(): | ||
""" | ||
Test that when creating snapshots on Openstack provider the Description field is mandatory. | ||
|
||
Polarion: | ||
assignee: apagac | ||
casecomponent: Cloud | ||
caseimportance: high | ||
initialEstimate: 1/4h | ||
setup: | ||
1. Have OSP provider added and test VM created | ||
testSteps: | ||
1. Try to create a snapshot with no description | ||
2. Try to create a snapshot with description | ||
expectedResults: | ||
1. Snapshot not created; 'Required' displayed | ||
2. Snapshot created successfully | ||
Bugzilla: | ||
1647916 | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. @apagac since you are putting in the BZ metadata, can you also add it to the top of the file? There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. and the same for other tests |
||
""" | ||
pass |
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -2674,3 +2674,142 @@ def test_tenant_template_visibility(): | |
initialEstimate: 1/10h | ||
""" | ||
pass | ||
|
||
|
||
@pytest.mark.manual | ||
@test_requirements.rbac | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. same here for the requirements, I think it's better to define at the module level |
||
@pytest.mark.tier(2) | ||
def test_create_higher_permission_child_tenant(): | ||
""" | ||
Test creating a group with higher permission that the user currently has on a new tenant. | ||
|
||
Polarion: | ||
assignee: apagac | ||
casecomponent: Configuration | ||
caseimportance: medium | ||
initialEstimate: 1/4h | ||
testSteps: | ||
1. Create child tenant: "My tenant" | ||
2. Create group with: | ||
- "My Tenant admin group" with role: "EvmRole-tenant_administrator" | ||
- Tenant: "My tenant" | ||
3. Create tenant admin user "tenantadmin" with group "My Tenant admin group" | ||
4. login as tenant admin | ||
5. Try to create group with EvmRole-super_administrator | ||
expectedResults: | ||
1. | ||
2. | ||
3. | ||
4. | ||
5. EvmRole-super_administrator should not be available | ||
Bugzilla: | ||
1418297 | ||
""" | ||
pass | ||
|
||
|
||
@pytest.mark.manual | ||
@test_requirements.rbac | ||
@pytest.mark.tier(2) | ||
def test_create_higher_permission(): | ||
""" | ||
Test creating a group with higher permission that the user currently has. | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Is it the correct description? I don't see group creation in the test steps... |
||
|
||
Polarion: | ||
assignee: apagac | ||
casecomponent: Configuration | ||
caseimportance: medium | ||
initialEstimate: 1/4h | ||
testSteps: | ||
1. Create user with tenant_administrator role | ||
2. Log in as that user | ||
3. Go to Users | ||
expectedResults: | ||
1. | ||
2. | ||
3. Users without super-administator role and administator role visible | ||
Bugzilla: | ||
1447370 | ||
""" | ||
pass | ||
|
||
|
||
@pytest.mark.manual | ||
@test_requirements.rbac | ||
@pytest.mark.tier(2) | ||
def test_multiple_notifications(): | ||
""" | ||
Test that user that is a member of multiple groups receives only one notification. | ||
|
||
Polarion: | ||
assignee: apagac | ||
casecomponent: Configuration | ||
caseimportance: medium | ||
initialEstimate: 1/4h | ||
testSteps: | ||
1. Create a user, assign him to multiple groups | ||
2. As the user, provision a VM | ||
expectedResults: | ||
1. | ||
2. Only one notification displayed upon successfull provision | ||
Bugzilla: | ||
1549898 | ||
""" | ||
pass | ||
|
||
|
||
@pytest.mark.manual | ||
@test_requirements.rbac | ||
@pytest.mark.tier(2) | ||
def test_cluster_filters(): | ||
""" | ||
Test that filters work even when deleting the item they were in place for. | ||
|
||
Polarion: | ||
assignee: apagac | ||
casecomponent: Configuration | ||
caseimportance: medium | ||
initialEstimate: 1/4h | ||
setup: | ||
1. Have a provider with multiple Datastores and Clusters. | ||
2. Assume you have Datastore1 with Cluster1 and Datastore2 with Cluster2 | ||
testSteps: | ||
1. Create a role and group with the filters for only Cluster1 | ||
2. Create a user with this group | ||
3. Login and verify that you can see only Cluster1 | ||
4. Delete Datastore1 (with Cluster1) | ||
5. Verify the user now can't see any cluster | ||
expectedResults: | ||
1. | ||
2. | ||
3. User can see only Cluster1 | ||
4. | ||
5. User can't see any Cluster | ||
Bugzilla: | ||
1693183 | ||
""" | ||
pass | ||
|
||
|
||
@pytest.mark.manual | ||
@test_requirements.rbac | ||
@pytest.mark.tier(2) | ||
def test_delete_custom_super_admin(): | ||
""" | ||
Test that custom user with super_administrator group can be deleted. | ||
|
||
Polarion: | ||
assignee: apagac | ||
casecomponent: Configuration | ||
caseimportance: medium | ||
initialEstimate: 1/4h | ||
testSteps: | ||
1. Create a new user with group EvmGroup-super_administrator | ||
2. Try to delete this user | ||
expectedResults: | ||
1. | ||
2. User successfully deleted | ||
Bugzilla: | ||
1720273 | ||
""" | ||
pass |
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -1535,3 +1535,72 @@ def test_session_timeout(): | |
title: Verify session timeout works fine for external auth. | ||
""" | ||
pass | ||
|
||
|
||
@pytest.mark.manual | ||
@test_requirements.auth | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Same for the requirements as above |
||
@pytest.mark.tier(2) | ||
def test_certmonger_service(): | ||
""" | ||
Test that the certmonger service is running after SSL certs have been setup and appliance | ||
rebooted. | ||
|
||
Polarion: | ||
assignee: apagac | ||
casecomponent: Configuration | ||
caseimportance: medium | ||
initialEstimate: 1/4h | ||
setup: | ||
1. Have IDM (freeipa) server up and running | ||
testSteps: | ||
1. Configure appliance to use external auth via IDM server: | ||
appliance_console_cli \ | ||
--ipaserver=<IPA_HOSTNAME> \ | ||
--ipaprincipal=<IPA_PRINCIPAL> \ | ||
--ipapassword=<IPA_PASSWD> | ||
2. Setup SSL certs on the appliance: | ||
appliance_console_cli \ | ||
--ca=ipa \ | ||
--http-cert | ||
3. Reboot the appliance | ||
4. View status of the certmonger service: | ||
systemctl status certmonger | ||
expectedResults: | ||
1. Appliance configured. | ||
2. Certs installed | ||
3. Appliance rebooted | ||
4. certmonger service running | ||
Bugzilla: | ||
1670604 | ||
""" | ||
pass | ||
|
||
|
||
@pytest.mark.manual | ||
@test_requirements.auth | ||
@pytest.mark.tier(2) | ||
def test_group_lookup_oidc(): | ||
""" | ||
Test that group lookup is disabled when using OpenID-Connect. | ||
|
||
Polarion: | ||
assignee: apagac | ||
casecomponent: Configuration | ||
caseimportance: medium | ||
initialEstimate: 1/4h | ||
testSteps: | ||
1. Configure your appliance to use External auth: | ||
Configuration -> Settings -> select Current Server -> Authentication -> Mode | ||
-> set to External | ||
2. On the same page, choose Provider Type: Enable OpenID-Connect | ||
3. Navigate to Configuration -> Access Control -> Create a new Group | ||
4. Ensure the "(Look up External Authentication Groups)" checkbox is not displayed | ||
expectedResults: | ||
1. Appliance configured | ||
2. OIDC enabled | ||
3. | ||
4. Checkbox not displayed | ||
Bugzilla: | ||
1609321 | ||
""" | ||
pass |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
All tests in this module have the same requirement, so please put it for the whole module
pytestmark = [test_requirements.snapshot]
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@lina-nikiforova some have
rbac
andauth
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Oh but they are different files, please ignore above 🤦♂️