Sha256: d2e0cb633d885ccf39706692561cee3fb898e06a41abc3b3e823c66a22e176dc

Contents?: true

Size: 1.25 KB

Versions: 140

Compression:

Stored size: 1.25 KB

Contents

Shindo.tests('Fog::Rackspace::LoadBalancers | virtual_ip_tests', ['rackspace']) do

  pending if Fog.mocking?

  given_a_load_balancer_service do
    given_a_load_balancer do
      tests('success') do

        @lb.wait_for { ready? }
        tests('#create_virtual_ip').formats(VIRTUAL_IP_FORMAT) do
          data = @service.create_virtual_ip(@lb.id, 'PUBLIC').body
          @virtual_ip_id = data['id']
          data
        end

        @lb.wait_for { ready? }
        tests("list_virtual_ips").formats(VIRTUAL_IPS_FORMAT) do
          @service.list_virtual_ips(@lb.id).body
        end
      end

      tests('failure') do
        #TODO - I feel like this should really be a BadRequest, need to dig in
        tests('create_virtual_ip(invalid type)').raises(Fog::Rackspace::LoadBalancers::InternalServerError) do
          @service.create_virtual_ip(@lb.id, 'badtype')
        end
        tests('delete_virtual_ip(0)').raises(Fog::Rackspace::LoadBalancers::BadRequest) do
          @service.delete_virtual_ip(@lb.id, 0)
        end
      end

      tests('success') do
        @lb.wait_for { ready? }
        tests("#delete_virtual_ip(#{@lb.id}, #{@virtual_ip_id})").succeeds do
          @service.delete_virtual_ip(@lb.id, @virtual_ip_id)
        end
      end
    end
  end
end

Version data entries

140 entries across 138 versions & 22 rubygems

Version Path
fog-maestrodev-1.18.0.20131206115947 tests/rackspace/requests/load_balancers/virtual_ip_tests.rb
fog-maestrodev-1.18.0.20131205181604 tests/rackspace/requests/load_balancers/virtual_ip_tests.rb
fog-maestrodev-1.18.0.20131127194823 tests/rackspace/requests/load_balancers/virtual_ip_tests.rb
fog-maestrodev-1.18.0.20131126183714 tests/rackspace/requests/load_balancers/virtual_ip_tests.rb
fog-maestrodev-1.18.0.20131126122111 tests/rackspace/requests/load_balancers/virtual_ip_tests.rb
fog-maestrodev-1.18.0.20131125111730 tests/rackspace/requests/load_balancers/virtual_ip_tests.rb
fog-maestrodev-1.18.0.20131125083406 tests/rackspace/requests/load_balancers/virtual_ip_tests.rb
fog-maestrodev-1.18.0.20131123105121 tests/rackspace/requests/load_balancers/virtual_ip_tests.rb
fog-maestrodev-1.18.0.20131122203507 tests/rackspace/requests/load_balancers/virtual_ip_tests.rb
fog-maestrodev-1.18.0.20131121075022 tests/rackspace/requests/load_balancers/virtual_ip_tests.rb
fog-maestrodev-1.18.0.20131118164830 tests/rackspace/requests/load_balancers/virtual_ip_tests.rb
fog-maestrodev-1.18.0.20131115184302 tests/rackspace/requests/load_balancers/virtual_ip_tests.rb
fog-maestrodev-1.18.0.20131114200144 tests/rackspace/requests/load_balancers/virtual_ip_tests.rb
gapinc-fog-1.12.1.2.1 tests/rackspace/requests/load_balancers/virtual_ip_tests.rb
fog-maestrodev-1.18.0.20131112185232 tests/rackspace/requests/load_balancers/virtual_ip_tests.rb
fog-maestrodev-1.18.0.20131111203459 tests/rackspace/requests/load_balancers/virtual_ip_tests.rb
fog-1.18.0 tests/rackspace/requests/load_balancers/virtual_ip_tests.rb
fog-1.17.0 tests/rackspace/requests/load_balancers/virtual_ip_tests.rb
fog-1.16.0 tests/rackspace/requests/load_balancers/virtual_ip_tests.rb
fog-maestrodev-1.15.0.20130927082724 tests/rackspace/requests/load_balancers/virtual_ip_tests.rb