diff --git a/app/views/devise/sessions/new.html.haml b/app/views/devise/sessions/new.html.haml index 565419c..29fa3b0 100644 --- a/app/views/devise/sessions/new.html.haml +++ b/app/views/devise/sessions/new.html.haml @@ -22,7 +22,7 @@ = f.label :remember_me %div.buttons - %button{:type => 'submit', :class => 'sign_in'}= "Sign in" + %button{:type => 'submit', :class => 'sign_in'}=t('.sign_in') :javascript $('a#forgot_password').click(function(){ diff --git a/config/locales/en.yml b/config/locales/en.yml index ade58a0..7e6b8f8 100644 --- a/config/locales/en.yml +++ b/config/locales/en.yml @@ -65,6 +65,9 @@ en: omniauth_callbacks: failure: "Could not authenticate you from %{kind} because \"%{reason}\"." success: "Successfully authenticated from %{kind} account." + sessions: + new: + sign_in: "Sign in" apps: index: diff --git a/spec/acceptance/sign_in_with_github_spec.rb b/spec/acceptance/sign_in_with_github_spec.rb index 7b760c1..b02bc01 100644 --- a/spec/acceptance/sign_in_with_github_spec.rb +++ b/spec/acceptance/sign_in_with_github_spec.rb @@ -1,6 +1,7 @@ require 'acceptance/acceptance_helper' feature 'Sign in with GitHub' do + background do Errbit::Config.stub(:github_authentication) { true } Fabricate(:user, :github_login => 'nashby') diff --git a/spec/acceptance/watch_unwatch_app.rb b/spec/acceptance/watch_unwatch_app.rb new file mode 100644 index 0000000..4087221 --- /dev/null +++ b/spec/acceptance/watch_unwatch_app.rb @@ -0,0 +1,23 @@ +require 'acceptance/acceptance_helper' + +feature 'A user can watch and unwatch an application' do + + let!(:app) { Fabricate(:app) } + let!(:user) do + user = Fabricate(:user) + app.watchers.create!( + :user_id => user.id + ) + user.reload + end + + scenario 'log in watch a project and unwatch it' do + visit '/' + fill_in :user_email, :with => user.email + fill_in :user_password, :with => 'password' + click_on I18n.t('devise.sessions.new.sign_in') + click_on I18n.t('apps.show.unwatch') + expect(page).to have_content(I18n.t('apps.index.no_apps') + end + +end -- libgit2 0.21.2