Skip to content
This repository was archived by the owner on Apr 7, 2022. It is now read-only.

Commit c65205d

Browse files
authored
[1LP][RFR] Add test_infrastructure_hosts_tagging (#10182)
* Automate test_infrastructure_hosts_tagging
1 parent 104b575 commit c65205d

File tree

2 files changed

+20
-31
lines changed

2 files changed

+20
-31
lines changed

cfme/tests/infrastructure/test_host.py

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -617,3 +617,23 @@ def test_infrastructure_hosts_crud(appliance, setup_provider):
617617
# Case6 - lastly do the delete. First try is canceled.
618618
host.delete(cancel=True)
619619
host.delete
620+
621+
622+
@test_requirements.infra_hosts
623+
def test_infrastructure_hosts_tagging(appliance, setup_provider):
624+
"""
625+
Polarion:
626+
assignee: prichard
627+
casecomponent: Infra
628+
caseimportance: high
629+
initialEstimate: 1/6h
630+
"""
631+
host = appliance.collections.hosts.all()[0]
632+
tag = host.add_tag()
633+
host_tags = host.get_tags()
634+
assert any(
635+
tag.category.display_name == host_tag.category.display_name and
636+
tag.display_name == host_tag.display_name
637+
for host_tag in host_tags
638+
), "tag is not assigned"
639+
host.remove_tag(tag)

cfme/tests/infrastructure/test_host_manual.py

Lines changed: 0 additions & 31 deletions
Original file line numberDiff line numberDiff line change
@@ -565,37 +565,6 @@ def test_host_viewing():
565565
pass
566566

567567

568-
@test_requirements.infra_hosts
569-
def test_host_tagging():
570-
"""
571-
Testing tagging hosts.
572-
573-
574-
Polarion:
575-
assignee: prichard
576-
casecomponent: Infra
577-
caseimportance: high
578-
initialEstimate: 1/4h
579-
testSteps:
580-
1. Navigate to the Compute > Infrastructure > Hosts view.
581-
2. Click checkbox in quadicon to select a host.
582-
3. Click Edit Tags in the Policy dropdown.
583-
4. Select a customer tag from the first dropdown and then a value for the tag.
584-
5. Click save.
585-
6. Click on the same quadicon as in step 2.
586-
7. Repeat steps 1 thru 6, but select multiple hosts.
587-
expectedResults:
588-
1. Hosts view is displayed.
589-
2.
590-
3. Tag Assignement view is displayed.
591-
4.
592-
5. "Tag edits successfully saved." message is displayed.
593-
6. Tags added in step 4 are displayed in Smart Management section of hosts summary.
594-
7. Expected results are the same as steps 1 thru 6 for multiple hosts.
595-
"""
596-
pass
597-
598-
599568
@test_requirements.infra_hosts
600569
def test_host_drift_analysis():
601570
"""

0 commit comments

Comments
 (0)