Sha256: fb78562d4293aa5d04c03f50f6eb972f17f54ac249ad22245f97967d6bca4262
Contents?: true
Size: 1.28 KB
Versions: 1
Compression:
Stored size: 1.28 KB
Contents
require 'spec_helper' describe Squall::IpAddressJoin do before(:each) do @join = Squall::IpAddressJoin.new end describe "#list" do use_vcr_cassette 'ipaddress_join/list' it "requires virtual machine ID" do expect { @join.list }.to raise_error(ArgumentError) end it "returns list of ip_addresses" do ips = @join.list(1) ips.should be_an(Array) end it "contains IP address data" do ips = @join.list(1) ips.all?.should be_true end end describe "#assign" do use_vcr_cassette "ipaddress_join/assign" it "raises ArgumentError without required arguments" do expect { @join.assign }.to raise_error(ArgumentError) expect { @join.assign(1) }.to raise_error(ArgumentError) end it "assigns the IP join" do join = @join.assign(1, {:ip_address_id => 1, :network_interface_id => 1}) @join.success.should be_true end end describe "#delete" do use_vcr_cassette "ipaddress_join/delete" it "raises ArgumentError without required arguments" do expect { @join.delete }.to raise_error(ArgumentError) expect { @join.delete(1) }.to raise_error(ArgumentError) end it "deletes the IP join" do @join.delete(1, 1) @join.success.should be_true end end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
squall-1.3.0 | spec/squall/ip_address_join_spec.rb |