提交 3f51df04 编写于 作者: M Mark Lapierre

Allow login validation before block

Removes a block so that the login page is validated before the block,
while the login page is still present, instead of after it when the
login page is long gone
上级 8ab0db4e
......@@ -25,15 +25,12 @@ module QA
private
def create_personal_access_token
if @is_new_session
Runtime::Browser.visit(@address, Page::Main::Login) { do_create_personal_access_token }
else
do_create_personal_access_token
end
Runtime::Browser.visit(@address, Page::Main::Login) if @is_new_session
do_create_personal_access_token
end
def do_create_personal_access_token
Page::Main::Login.act { sign_in_using_credentials }
Page::Main::Login.perform(&:sign_in_using_credentials)
Resource::PersonalAccessToken.fabricate!.access_token
end
end
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册