Sha256: 0ec17095f623e571f4c4608db86ef56dad0c2dd57f1607d0b3ae3f82b65a4305

Contents?: true

Size: 446 Bytes

Versions: 176

Compression:

Stored size: 446 Bytes

Contents

RSpec::Matchers.define :be_attached_to do |instance_id|
  match do |type|
    # NetworkInterface
    if type.instance_of?(Awspec::Type::NetworkInterface)
      return type.attached_to?(instance_id, @device_index)
    end
    type.attached_to?(instance_id)
  end

  chain :device_index do |device_index|
    @device_index = device_index
  end

  (0..10).each do |idx|
    chain "as_eth#{idx}".to_sym do
      @device_index = idx
    end
  end
end

Version data entries

176 entries across 176 versions & 4 rubygems

Version Path
cthiesfork-awspec-1.2.2 lib/awspec/matcher/be_attached_to.rb
cthiesfork-awspec-1.2.1 lib/awspec/matcher/be_attached_to.rb
awspec-1.18.5 lib/awspec/matcher/be_attached_to.rb
cthiesfork-awspec-1.2.0 lib/awspec/matcher/be_attached_to.rb
cthiesfork-awspec-1.1.0 lib/awspec/matcher/be_attached_to.rb
cthiesfork-awspec-1.0.0 lib/awspec/matcher/be_attached_to.rb
awspec-1.18.4 lib/awspec/matcher/be_attached_to.rb
awspec-1.18.3 lib/awspec/matcher/be_attached_to.rb
awspec-1.18.2 lib/awspec/matcher/be_attached_to.rb
awspec-1.18.1 lib/awspec/matcher/be_attached_to.rb
awspec-1.18.0 lib/awspec/matcher/be_attached_to.rb
awspec-1.17.4 lib/awspec/matcher/be_attached_to.rb
awspec-1.17.3 lib/awspec/matcher/be_attached_to.rb
awspec-1.17.2 lib/awspec/matcher/be_attached_to.rb
awspec-1.17.1 lib/awspec/matcher/be_attached_to.rb
awspec-1.17.0 lib/awspec/matcher/be_attached_to.rb
awspec-1.16.1 lib/awspec/matcher/be_attached_to.rb
awspec-1.16.0 lib/awspec/matcher/be_attached_to.rb
awspec-1.15.3 lib/awspec/matcher/be_attached_to.rb
awspec-1.15.2 lib/awspec/matcher/be_attached_to.rb