Project

General

Profile

« Previous | Next » 

Revision 5c02935a

Added by Dominic Cleal about 8 years ago

fixes #14291 - replace integration test logins with SSO

Replace the loading and form-filling on the user login page with a
test-only SSO method, which automatically logs in the test user on
every request. This uses a cookie sent in the request to specify the
user.

View differences:

test/integration/user_test.rb
assert_submit_button(users_path)
assert page.has_link? 'user12345'
end
context "without automatic login" do
def login_admin; end
test "login" do
visit "/"
fill_in "login_login", :with => users(:admin).login
fill_in "login_password", :with => "secret"
click_button "Login"
assert_current_path hosts_path
end
end
end

Also available in: Unified diff