def test_selecting_one_version_doesnt_show_other_versions(self, base_url, selenium): maximum_checks = 20 # limits the number of reports to check csp = CrashStatsHomePage(base_url, selenium) product = csp.header.current_product versions = csp.header.current_versions version = str(versions[1]) csp.header.select_version(version) report_list = csp.click_last_product_top_crashers_link() crash_report_page = report_list.click_first_signature() crash_report_page.click_reports_tab() reports = crash_report_page.reports assert len(reports) > 0, 'reports not found for signature' random_indexes = csp.get_random_indexes(reports, maximum_checks) for index in random_indexes: report = reports[index] assert product == report.product
def test_selecting_one_version_doesnt_show_other_versions(self, mozwebqa): maximum_checks = 20 # limits the number of reports to check csp = CrashStatsHomePage(mozwebqa) product = csp.header.current_product versions = csp.header.current_versions version = str(versions[1]) csp.header.select_version(version) report_list = csp.click_last_product_top_crashers_link() crash_report_page = report_list.click_first_signature() crash_report_page.click_reports_tab() reports = crash_report_page.reports Assert.true(len(reports) > 0, "reports not found for signature") random_indexes = csp.get_random_indexes(reports, maximum_checks) for index in random_indexes: report = reports[index] Assert.equal(report.product, product)
def test_selecting_one_version_doesnt_show_other_versions(self, base_url, selenium): maximum_checks = 20 # limits the number of reports to check csp = CrashStatsHomePage(selenium, base_url).open() product = csp.header.current_product versions = csp.header.current_versions version = str(versions[1]) csp.header.select_version(version) report_list = csp.release_channels[-1].click_top_crasher() crash_report_page = report_list.click_first_signature() crash_report_page.click_reports_tab() reports = crash_report_page.reports assert len(reports) > 0, 'reports not found for signature' random_indexes = csp.get_random_indexes(reports, maximum_checks) for index in random_indexes: report = reports[index] assert product == report.product