def test_login_without_account_and_pwd(self, login): with allure.step("1、点击登录按钮"): login.click_login_btn() time.sleep(0.5) with allure.step("2、断言"): assert LoginPage.get_account_error( login) == test_login['account_error'] assert LoginPage.get_pwd_error( login) == test_login['password_error']
def test_login_without_password(self, login): with allure.step("1、输入账号"): login.input_account(test_login['account']) with allure.step("2、点击登录按钮"): login.click_login_btn() time.sleep(0.5) with allure.step("3、断言"): # print(LoginPage.get_account_error(login)) assert LoginPage.get_pwd_error( login) == test_login['password_error']