2011-01-03 11:23:51 -08:00
|
|
|
for provider, config in storage_providers
|
2010-11-16 15:31:34 -08:00
|
|
|
|
2012-08-15 16:19:32 +01:00
|
|
|
Shindo.tests("Storage[:#{provider}] | directory", [provider.to_s]) do
|
2010-11-03 18:17:20 -07:00
|
|
|
|
2011-05-24 17:32:27 -07:00
|
|
|
if !Fog.mocking? || config[:mocked]
|
2010-11-03 18:17:20 -07:00
|
|
|
|
2011-05-24 17:32:27 -07:00
|
|
|
directory_attributes = {
|
|
|
|
:key => 'fogdirectorytests'
|
|
|
|
}.merge!(config[:directory_attributes] || {})
|
2011-01-03 11:23:51 -08:00
|
|
|
|
2011-09-20 11:03:56 -05:00
|
|
|
model_tests(Fog::Storage[provider].directories, directory_attributes, config[:mocked]) do
|
2011-05-24 17:32:27 -07:00
|
|
|
|
|
|
|
tests("#public=(true)").succeeds do
|
|
|
|
pending if Fog.mocking? && !config[:mocked]
|
|
|
|
@instance.public=(true)
|
|
|
|
end
|
|
|
|
|
|
|
|
tests('responds_to(:public_url)') do
|
|
|
|
pending if Fog.mocking? && !config[:mocked]
|
2011-09-20 11:03:56 -05:00
|
|
|
responds_to(:public_url)
|
2011-05-24 17:32:27 -07:00
|
|
|
end
|
2011-01-03 11:23:51 -08:00
|
|
|
|
|
|
|
end
|
2010-11-05 11:37:12 -07:00
|
|
|
|
2010-11-16 15:31:34 -08:00
|
|
|
end
|
2010-11-05 11:37:12 -07:00
|
|
|
|
2010-11-03 18:17:20 -07:00
|
|
|
end
|
|
|
|
|
2010-11-11 13:54:55 -06:00
|
|
|
end
|