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

Commit

Permalink
Add GH blocker and use eq over cmp
Browse files Browse the repository at this point in the history
  • Loading branch information
john-dupuy committed Dec 10, 2019
1 parent 5026fdf commit 6ec5f9b
Show file tree
Hide file tree
Showing 7 changed files with 20 additions and 11 deletions.
5 changes: 3 additions & 2 deletions cfme/infrastructure/config_management/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
from manageiq_client.api import Entity as RestEntity
from navmazing import NavigateToAttribute
from navmazing import NavigateToSibling
from navmazing import NavigationDestinationNotFound
from widgetastic.widget import Checkbox
from widgetastic.widget import Text
from widgetastic.widget import TextInput
Expand Down Expand Up @@ -245,7 +246,7 @@ def is_displayed(self):
return self.entities.title.text == title


@attr.s(cmp=False)
@attr.s(eq=False)
class ConfigManagerProvider(BaseProvider, Updateable, Pretty):
"""
This is base class for Configuration manager objects (Red Hat Satellite, Foreman, Ansible Tower)
Expand Down Expand Up @@ -594,7 +595,7 @@ def step(self, *args, **kwargs):
class ConfigManagerAllPage(CFMENavigateStep):

def step(self, *args, **kwargs):
raise NotImplementedError(
raise NavigationDestinationNotFound(
"There is no page in MIQ that displays all config managers."
" Use 'AllOfType' on a config manager provider instance."
)
2 changes: 1 addition & 1 deletion cfme/infrastructure/config_management/ansible_tower.py
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ def is_displayed(self):
)


@attr.s(cmp=False)
@attr.s(eq=False)
class AnsibleTowerProvider(ConfigManagerProvider):
"""
Configuration manager object (Ansible Tower)
Expand Down
7 changes: 3 additions & 4 deletions cfme/infrastructure/config_management/config_profiles.py
Original file line number Diff line number Diff line change
Expand Up @@ -26,10 +26,9 @@ class ConfigProfile(BaseEntity, Pretty):

@property
def type(self):
kind = "Configuration Profile"
if self.manager.type == "ansible_tower":
kind = "Inventory Group"
return kind
return (
"Inventory Group" if self.manager.type == "ansible_tower" else "Configuration Profile"
)

@property
def config_systems(self):
Expand Down
2 changes: 1 addition & 1 deletion cfme/infrastructure/config_management/satellite.py
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ def is_displayed(self):
)


@attr.s(cmp=False)
@attr.s(eq=False)
class SatelliteProvider(ConfigManagerProvider):
"""
Configuration manager object (Red Hat Satellite, Foreman)
Expand Down
6 changes: 3 additions & 3 deletions cfme/tests/infrastructure/test_config_management.py
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@

pytestmark = [
pytest.mark.provider([AnsibleTowerProvider, SatelliteProvider], scope='module'),
pytest.mark.usefixtures('setup_provider')
pytest.mark.usefixtures('setup_provider_modscope')
]


Expand Down Expand Up @@ -132,7 +132,7 @@ def test_config_system_tag(config_system, tag):


@pytest.mark.tier(3)
@pytest.mark.provider([AnsibleTowerProvider])
@pytest.mark.provider([AnsibleTowerProvider], scope='module')
def test_ansible_tower_job_templates_tag(request, provider, tag):
"""
Polarion:
Expand All @@ -159,7 +159,7 @@ def test_ansible_tower_job_templates_tag(request, provider, tag):


@pytest.mark.tier(3)
@pytest.mark.provider([AnsibleTowerProvider])
@pytest.mark.provider([AnsibleTowerProvider], scope='module')
@pytest.mark.parametrize('template_type', TEMPLATE_TYPE.values(), ids=list(TEMPLATE_TYPE.keys()))
def test_ansible_tower_service_dialog_creation_from_template(provider, template_type):
"""
Expand Down
4 changes: 4 additions & 0 deletions cfme/tests/webui/test_advanced_search.py
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@
from cfme.services.workloads import VmsInstances
from cfme.utils.appliance.implementations.ui import navigate_to
from cfme.utils.blockers import BZ
from cfme.utils.blockers import GH

SearchParam = namedtuple("SearchParam",
["collection", "destination", "entity", "filter", "my_filters"])
Expand Down Expand Up @@ -296,11 +297,13 @@ class TestContainers(object):


@inject_tests
@pytest.mark.meta(blockers=[GH('ManageIQ/integration_tests:9723')])
class TestAnsibleTower(object):
params_values = [
SearchParam('ansible_tower_providers', 'All', 'ansible_tower_explorer_provider',
'Automation Manager (Ansible Tower) : Name',
('sidebar.providers', 'All Ansible Tower Providers')),

SearchParam('ansible_tower_systems', 'All', 'ansible_tower_explorer_system',
'Configured System (Ansible Tower) : Hostname',
('sidebar.configured_systems', 'All Ansible Tower Configured Systems')),
Expand Down Expand Up @@ -329,6 +332,7 @@ class TestStorage(object):


@inject_tests
@pytest.mark.meta(blockers=[GH('ManageIQ/integration_tests:9723')])
class TestConfigManagement(object):
params_values = [
SearchParam(ConfigManagerProvider, 'All', 'configuration_management',
Expand Down
5 changes: 5 additions & 0 deletions conf/supportability.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -31,3 +31,8 @@
- 3.7
- 3.9
- 3.11
config_manager:
- satellite:
- 6.2
- ansible_tower:
- 3.10

0 comments on commit 6ec5f9b

Please sign in to comment.