def test_load_same_manifest_to_same_org_wo_force(self, mozwebqa): ''' Scenario 2 with a twist. Import Manifest (M1) from Distributor (D1) into Org1 w/o useing force. Result: Expect Fail ''' sysapi = ApiTasks(mozwebqa) home_page = Home(mozwebqa) new_org_name = "manifest%s" % home_page.random_string() sysapi.create_org(new_org_name) home_page.login() home_page.header.click_switcher() home_page.header.filter_org_in_switcher(new_org_name) home_page.header.click_filtered_result(new_org_name) cm = ContentManagementTab(mozwebqa) home_page.tabs.click_tab("content_management_tab") if home_page.project == "katello" or home_page.project == "cfse": cm.click_content_providers() cm.select_redhat_content_provider() cm.enter_manifest(os.path.realpath(self._scenario2_m1_d1_manifest)) cm.enter_manifest(os.path.realpath(self._scenario2_m1_d1_manifest)) Assert.true(home_page.is_failed)
def test_load_manifest(self, mozwebqa): ''' Scenario 1: Import Manifest (M1) from Distributor (D1) input Org1 Result: Pass ''' sysapi = ApiTasks(mozwebqa) home_page = Home(mozwebqa) new_org_name = "manifest%s" % home_page.random_string() sysapi.create_org(new_org_name) home_page.login() home_page.header.click_switcher() home_page.header.filter_org_in_switcher(new_org_name) home_page.header.click_filtered_result(new_org_name) cm = ContentManagementTab(mozwebqa) home_page.tabs.click_tab("content_management_tab") if home_page.project == "katello" or home_page.project == "cfse": cm.click_content_providers() cm.select_redhat_content_provider() cm.enter_manifest(os.path.realpath(self._org1_m1_manifest)) Assert.true(home_page.is_successful) Assert.not_equal(cm.get_content_table_text, "No subscriptions have been imported.")
def test_load_new_manifest_into_same_org_wo_force(self, mozwebqa): ''' Scenario 5: Load updated (new) manifest into org where a manifest already exists. Result: Pass ''' sysapi = ApiTasks(mozwebqa) home_page = Home(mozwebqa) new_org_name = "manifest-%s" % home_page.random_string() sysapi.create_org(new_org_name) home_page.login() home_page.header.click_switcher() home_page.header.filter_org_in_switcher(new_org_name) home_page.header.click_filtered_result(new_org_name) cm = ContentManagementTab(mozwebqa) home_page.tabs.click_tab("content_management_tab") if home_page.project == "katello" or home_page.project == "cfse": cm.click_content_providers() cm.select_redhat_content_provider() cm.enter_manifest(os.path.realpath(self._scenario5_o1_m1_manifest)) cm.enter_manifest(os.path.realpath(self._scenario5_o1_m2_manifest)) Assert.true(home_page.is_successful) Assert.not_equal(cm.get_content_table_text, "No subscriptions have been imported.")
def test_NumberFormatException_forInputString(self, mozwebqa): """ Regression Test for bz786963 """ home_page = Home(mozwebqa) sysapi = ApiTasks(mozwebqa) new_org_name = "manifest-%s" % home_page.random_string() sysapi.create_org(new_org_name) home_page.login() home_page.header.click_switcher() home_page.header.filter_org_in_switcher(new_org_name) home_page.header.click_filtered_result(new_org_name) cm = ContentManagementTab(mozwebqa) home_page.tabs.click_tab("content_management_tab") if home_page.project == "katello" or home_page.project == "cfse": cm.click_content_providers() cm.select_redhat_content_provider() cm.enter_manifest(os.path.realpath(self._bz786963_manifest)) Assert.true(home_page.is_successful) Assert.not_equal(cm.get_content_table_text, "No subscriptions have been imported.")
def test_load_same_manifest_to_same_org_w_force(self, mozwebqa): ''' Scenario 2: Re-import same manifest into same org. Result: Pass ''' home_page = Home(mozwebqa) sysapi = ApiTasks(mozwebqa) new_org_name = "manifest-%s" % home_page.random_string() sysapi.create_org(new_org_name) home_page.login() home_page.header.click_switcher() home_page.header.filter_org_in_switcher(new_org_name) home_page.header.click_filtered_result(new_org_name) cm = ContentManagementTab(mozwebqa) home_page.tabs.click_tab("content_management_tab") ''' Need to clean this up a bit ''' if home_page.project == "katello" or home_page.project == "cfse": cm.click_content_providers() cm.select_redhat_content_provider() cm.enter_manifest(os.path.realpath(self._org4_m1_manifest)) cm.click_force() cm.enter_manifest(os.path.realpath(self._org4_m1_manifest)) Assert.true(home_page.is_successful)