diff options
author | jessib <jessib@riseup.net> | 2013-09-09 13:54:29 -0700 |
---|---|---|
committer | jessib <jessib@riseup.net> | 2013-09-09 13:54:29 -0700 |
commit | e8a2db42813dc3f5d1ebb95eb896455d7a922505 (patch) | |
tree | 8b97e98adb5c7c2a6c093faf2cbc6bf014cb52cc | |
parent | 3ef22b5a856e1f576fb0a6a589b6b7ab41e1dd18 (diff) | |
parent | e11c158a15d54aea0eaefe698e7466634bacf204 (diff) |
Merge branch 'develop' into feature/only_lower_case_aliases
-rw-r--r-- | .gitmodules | 2 | ||||
-rw-r--r-- | users/app/views/sessions/new.html.haml | 2 | ||||
-rw-r--r-- | users/test/integration/browser/account_test.rb | 12 |
3 files changed, 13 insertions, 3 deletions
diff --git a/.gitmodules b/.gitmodules index afce01f..7884a42 100644 --- a/.gitmodules +++ b/.gitmodules @@ -1,3 +1,3 @@ [submodule "users/app/assets/javascripts/srp"] path = users/app/assets/javascripts/srp - url = git://leap.se/srp_js + url = https://leap.se/git/srp_js diff --git a/users/app/views/sessions/new.html.haml b/users/app/views/sessions/new.html.haml index c915968..0939e00 100644 --- a/users/app/views/sessions/new.html.haml +++ b/users/app/views/sessions/new.html.haml @@ -2,7 +2,7 @@ .span9 = render :partial => 'users/warnings' %h2=t :login - = simple_form_for @session, :validate => true, :html => { :id => :new_session, :class => 'form-horizontal' } do |f| + = simple_form_for [:api, @session], :validate => true, :html => { :id => :new_session, :class => 'form-horizontal' } do |f| = f.input :login, :required => false, :label => t(:username), :input_html => { :id => :srp_username } = f.input :password, :required => false, :input_html => { :id => :srp_password } .form-actions diff --git a/users/test/integration/browser/account_test.rb b/users/test/integration/browser/account_test.rb index 8b214a4..a5ec2c5 100644 --- a/users/test/integration/browser/account_test.rb +++ b/users/test/integration/browser/account_test.rb @@ -18,10 +18,20 @@ class AccountTest < BrowserIntegrationTest user.destroy end + test "successful login" do + username, password = submit_signup + click_on 'Logout' + click_on 'Log In' + fill_in 'Username', with: username + fill_in 'Password', with: password + click_on 'Log In' + assert page.has_content?("Welcome #{username}") + end + # trying to seed an invalid A for srp login test "detects attempt to circumvent SRP" do user = FactoryGirl.create :user - visit '/sessions/new' + visit '/login' fill_in 'Username', with: user.login fill_in 'Password', with: "password" inject_malicious_js |