コード例 #1
0
 def test_list_to_json_UAT(self) -> None:
     import deployment_log_UAT
     inst = deployment_log_UAT.test_fixtures(deployment_log_UAT.NAME)
     response = inst.consult_url(self.test_url)
     list_of_dictionaries = response.json()['issues']
     assert isinstance(inst.list_to_json(list(), list_of_dictionaries[0]),
                       dict)
     assert len(list_of_dictionaries[0]) > 0
コード例 #2
0
 def test_status_code_UAT(self) -> None:
     import deployment_log_UAT
     inst = deployment_log_UAT.test_fixtures(deployment_log_UAT.NAME)
     response = inst.consult_url(self.test_url)
     if '4' in str(response.status_code)[0]:
         raise Exception("Password is probably wrong")
     if '5' in str(response.status_code)[0]:
         raise Exception("Check if JIRA is down or the URL is wrong")
     self.assertEqual(response.status_code, 200)
コード例 #3
0
    def __init__(self, *args) -> None:
        import test_extraction_V2
        import jira_routine_V2
        import release_notes
        import deployment_log_UAT
        import barros_request

        super().__init__(*args)

        self.wdirectory = os.path.dirname(os.path.abspath(__file__))
        self.yml = self.load_yml()
        self.test_url = self.yml['unittest']['TEST_URL']
        self.TEST_watcher_1 = self.yml['unittest']['TEST_watcher_1']
        self.TEST_watcher_2 = self.yml['unittest']['TEST_watcher_2']
        self.TEST_call_1 = self.yml['unittest']['TEST_call_1']
        self.TEST_call_2 = self.yml['unittest']['TEST_call_2']
        self.instances = [
            test_extraction_V2.test_fixtures(test_extraction_V2.NAME),
            jira_routine_V2.test_fixtures(jira_routine_V2.NAME),
            release_notes.test_fixtures(release_notes.NAME),
            deployment_log_UAT.test_fixtures(deployment_log_UAT.NAME),
            barros_request.test_fixtures(barros_request.NAME)
        ]
コード例 #4
0
 def test_grab_tickets_UAT(self) -> None:
     import deployment_log_UAT
     inst = deployment_log_UAT.test_fixtures(deployment_log_UAT.NAME)
     grab = inst.grab_tickets(dict())
     assert isinstance(grab, dict)
     assert len(grab) > 0
コード例 #5
0
 def test_type_consult_url_UAT(self) -> None:
     import deployment_log_UAT
     inst = deployment_log_UAT.test_fixtures(deployment_log_UAT.NAME)
     assert isinstance(inst.consult_url(self.test_url), Response)