From d7f6d089d868d047eeb590b34b0954be9aa35665 Mon Sep 17 00:00:00 2001 From: Steven Miers Date: Thu, 30 Oct 2014 19:03:29 -0500 Subject: [PATCH] Use new test user account and port for build server. --- web/lib/youtube_client.rb | 2 +- web/spec/features/oauth_spec.rb | 4 ++-- web/spec/support/utilities.rb | 6 +++--- 3 files changed, 6 insertions(+), 6 deletions(-) diff --git a/web/lib/youtube_client.rb b/web/lib/youtube_client.rb index fa93046c8..9c733a1df 100644 --- a/web/lib/youtube_client.rb +++ b/web/lib/youtube_client.rb @@ -22,7 +22,7 @@ module JamRuby def initialize() Rails.logger.info("Initializing client...") self.config = Rails.application.config - self.redirect_uri='http://localhost:3000/auth/google_login/callback' + self.redirect_uri='http://localhost:2112/auth/google_login/callback' self.client = Google::APIClient.new( :application_name => 'JamKazam', :application_version => '1.0.0' diff --git a/web/spec/features/oauth_spec.rb b/web/spec/features/oauth_spec.rb index 2aca6d62b..ab879e30d 100644 --- a/web/spec/features/oauth_spec.rb +++ b/web/spec/features/oauth_spec.rb @@ -11,7 +11,7 @@ describe "OAuth", :js=>true, :type=>:feature, :capybara_feature=>true do Capybara.default_wait_time = 10 @previous_run_server = Capybara.run_server Capybara.run_server = false - @user=FactoryGirl.create(:user, :email=>"steven@jamkazam.com") + @user=FactoryGirl.create(:user, :email=>"jamkazamtest@gmail.com") end before(:each) do @@ -40,7 +40,7 @@ describe "OAuth", :js=>true, :type=>:feature, :capybara_feature=>true do end it "client should authorize a google user" do - authorize_google_user(@youtube_client, @user, "jam_2112") + authorize_google_user(@youtube_client, @user, "stinkyblueberryjam") save_screenshot("working.png") @user.reload @user.user_authorizations.count.should eq(1) diff --git a/web/spec/support/utilities.rb b/web/spec/support/utilities.rb index 17a211868..cb1268ba5 100644 --- a/web/spec/support/utilities.rb +++ b/web/spec/support/utilities.rb @@ -74,7 +74,7 @@ def wipe_s3_test_bucket end def authorize_google_user(youtube_client, user, google_password) - youtube_client.wait_for_callback do |access_token| + youtube_client.wait_for_callback(2112) do |access_token| #puts("Authorizing with token #{access_token}") user_auth_hash = { :provider => "google_login", @@ -104,11 +104,11 @@ def authorize_google_user(youtube_client, user, google_password) #save_screenshot("signin.png") - #save_screenshot("log1.png") + save_screenshot("submit.png") find('#submit_approve_access').trigger(:click) #save_screenshot("log2.png") sleep(5) - #save_screenshot("submitted.png") + save_screenshot("submitted.png") youtube_client end