Resolving constant redefinition warnings.
authorBob Aman <bobaman@google.com>
Tue, 31 Jul 2012 21:31:24 +0000 (00:31 +0300)
committerBob Aman <bobaman@google.com>
Tue, 31 Jul 2012 21:31:24 +0000 (00:31 +0300)
spec/google/api_client/batch_spec.rb
spec/google/api_client/discovery_spec.rb
spec/google/api_client/media_spec.rb
spec/google/api_client/result_spec.rb

index 315faaef61510e81ea39ad80072ad201bde23132..087210bec43c7c924a4e2c5eba2fbe55d9d633bf 100644 (file)
@@ -18,7 +18,7 @@ require 'google/api_client'
 require 'google/api_client/version'
 
 describe Google::APIClient::BatchRequest do
-  CLIENT = Google::APIClient.new
+  CLIENT ||= Google::APIClient.new
 
   after do
     # Reset client to not-quite-pristine state
index 5e363d4526de0e50d7b1e6b27fabfdf49359d9da..e196b0f53a9dc179c78c68370b10a7619f933eed 100644 (file)
@@ -29,7 +29,7 @@ require 'google/api_client'
 require 'google/api_client/version'
 
 describe Google::APIClient do
-  CLIENT = Google::APIClient.new
+  CLIENT ||= Google::APIClient.new
 
   after do
     # Reset client to not-quite-pristine state
index fd3be586975c96b4742d12ae6172618fccccaeaa..888a83cf80b5dc8cb011b150cf0c11fee5c01281 100644 (file)
@@ -58,7 +58,7 @@ describe Google::APIClient::UploadIO do
 end
 
 describe Google::APIClient::ResumableUpload do
-  CLIENT = Google::APIClient.new
+  CLIENT ||= Google::APIClient.new
 
   after do
     # Reset client to not-quite-pristine state
index f3fb8922740c4960b5ba20a197203c8d687b1097..d7c3326c203911f9820d4d118ac0cab1c9610760 100644 (file)
@@ -18,7 +18,7 @@ require 'google/api_client'
 require 'google/api_client/version'
 
 describe Google::APIClient::Result do
-  CLIENT = Google::APIClient.new
+  CLIENT ||= Google::APIClient.new
 
   describe 'with the plus API' do
     before do