Use new test user account and port for build server.

This commit is contained in:
Steven Miers 2014-10-30 19:03:29 -05:00
parent 41314f6892
commit d7f6d089d8
3 changed files with 6 additions and 6 deletions

View File

@ -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'

View File

@ -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)

View File

@ -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