Ver Fonte

only include threadsafe tests when using threadsafe

Peter McCracken há 11 anos atrás
pai
commit
8c415be31e
1 ficheiros alterados com 2 adições e 0 exclusões
  1. 2 0
      test/base_test.rb

+ 2 - 0
test/base_test.rb

@@ -80,7 +80,9 @@ class BaseTest < Test::Unit::TestCase
       ShopifyAPI::Base.headers['X-Custom'] = nil
       assert_nil ShopifyAPI::Product.headers['X-Custom']
     end
+  end
 
+  if ActiveResource::VERSION::MAJOR >= 4 && ActiveResource::VERSION::PRE == "threadsafe"
     test "#headers set in the main thread affect spawned threads" do
       ShopifyAPI::Base.headers['X-Custom'] = "the value"
       Thread.new do