Пример #1
0
 def test_login_success(self):
     test_function_data = self.test_class_data['test_login_success']
     self._testMethodDoc = test_function_data['testName']
     login_action = LoginAction(self.base_page.driver)
     main_page = login_action.login_sucessful(
         test_function_data['test_parameter'].get('username'),
         test_function_data['test_parameter'].get('password'))
     actual_result = main_page.get_username()
     self.assertEqual(actual_result, test_function_data['expectResult'],
                      test_function_data['message'])
Пример #2
0
 def test_login_success(self):
     login_action = LoginAction(self.base_page.driver)
     main_page = login_action.login_sucessful('test01', 'newdream123')
     actual_result = main_page.get_username()
     self.assertEqual(actual_result, '测试人员1', 'test_login_success执行失败')