Sha256: e33ae9017980600a495619ff3c00cd21b2c0501290377dd99ed3f240e35b6e2d

Contents?: true

Size: 1.47 KB

Versions: 22

Compression:

Stored size: 1.47 KB

Contents

Shindo.tests('Fog::Storage[:rackspace] | large object requests', ["rackspace"]) do

  unless Fog.mocking?
    @directory = Fog::Storage[:rackspace].directories.create(:key => 'foglargeobjecttests')
  end

  tests('success') do

    tests("#put_object('foglargeobjecttests', 'fog_large_object/1', ('x' * 6 * 1024 * 1024))").succeeds do
      pending if Fog.mocking?
      Fog::Storage[:rackspace].put_object(@directory.identity, 'fog_large_object/1', ('x' * 6 * 1024 * 1024))
    end

    tests("#put_object('foglargeobjecttests', 'fog_large_object/2', ('x' * 4 * 1024 * 1024))").succeeds do
      pending if Fog.mocking?
      Fog::Storage[:rackspace].put_object(@directory.identity, 'fog_large_object/2', ('x' * 4 * 1024 * 1024))
    end

    tests("#put_object_manifest('foglargeobjecttests', 'fog_large_object')").succeeds do
      pending if Fog.mocking?
      Fog::Storage[:rackspace].put_object_manifest(@directory.identity, 'fog_large_object')
    end

    tests("#get_object('foglargeobjecttests', 'fog_large_object').body").succeeds do
      pending if Fog.mocking?
      Fog::Storage[:rackspace].get_object(@directory.identity, 'fog_large_object').body == ('x' * 10 * 1024 * 1024)
    end

    unless Fog.mocking?
      ['fog_large_object', 'fog_large_object/1', 'fog_large_object/2'].each do |key|
        @directory.files.new(:key => key).destroy
      end
    end

  end

  tests('failure') do

    tests("put_object_manifest")

  end

  unless Fog.mocking?
    @directory.destroy
  end

end

Version data entries

22 entries across 22 versions & 9 rubygems

Version Path
hpfog-0.0.20 tests/rackspace/requests/storage/large_object_tests.rb
vagrant-shell-0.2.6 vendor/bundle/gems/fog-1.10.1/tests/rackspace/requests/storage/large_object_tests.rb
vagrant-shell-0.2.5 vendor/bundle/gems/fog-1.10.1/tests/rackspace/requests/storage/large_object_tests.rb
fog-nirvanix-1.8.2 tests/rackspace/requests/storage/large_object_tests.rb
fog-1.11.1 tests/rackspace/requests/storage/large_object_tests.rb
fog-1.11.0 tests/rackspace/requests/storage/large_object_tests.rb
fog-nirvanix-1.8.1 tests/rackspace/requests/storage/large_object_tests.rb
fog-1.10.1 tests/rackspace/requests/storage/large_object_tests.rb
fog-parser-fix-1.6.1 tests/rackspace/requests/storage/large_object_tests.rb
fog-test-again-1.6.0 tests/rackspace/requests/storage/large_object_tests.rb
fog-test-me-1.10.0 tests/rackspace/requests/storage/large_object_tests.rb
fog-parser-fix-1.6.0 tests/rackspace/requests/storage/large_object_tests.rb
fog-1.10.0 tests/rackspace/requests/storage/large_object_tests.rb
fog-1.9.0 tests/rackspace/requests/storage/large_object_tests.rb
fog-maestrodev-1.8.0.20130114204828 tests/rackspace/requests/storage/large_object_tests.rb
fog-maestrodev-1.8.0.20130111070250 tests/rackspace/requests/storage/large_object_tests.rb
fog-maestrodev-1.8.0.20130109172219 tests/rackspace/requests/storage/large_object_tests.rb
fog-sgonyea-1.8.1 tests/rackspace/requests/storage/large_object_tests.rb
fog-1.8.0 tests/rackspace/requests/storage/large_object_tests.rb
fog-maestrodev-1.7.0.20121114190951 tests/rackspace/requests/storage/large_object_tests.rb