Sha256: 92375610d7e25e9d403dea65f8509e3f5a4bde3799cd7321f1c3de1c5680af7f

Contents?: true

Size: 919 Bytes

Versions: 30

Compression:

Stored size: 919 Bytes

Contents

Shindo.tests('Fog::Compute[:libvirt] | interface model', ['libvirt']) do

  interfaces = Fog::Compute[:libvirt].interfaces
  interface = interfaces.last

  tests('The interface model should') do
    tests('have the action') do
      test('reload') { interface.respond_to? 'reload' }
    end
    tests('have attributes') do
      model_attribute_hash = interface.attributes
      attributes = [ :name, :mac, :active]
      tests("The interface model should respond to") do
        attributes.each do |attribute|
          test("#{attribute}") { interface.respond_to? attribute }
        end
      end
      tests("The attributes hash should have key") do
        attributes.each do |attribute|
          test("#{attribute}") { model_attribute_hash.key? attribute }
        end
      end
    end
    test('be a kind of Fog::Compute::Libvirt::Interface') { interface.kind_of? Fog::Compute::Libvirt::Interface }
  end

end

Version data entries

30 entries across 30 versions & 5 rubygems

Version Path
ns-fog-1.22.10 tests/libvirt/models/compute/interface_tests.rb
ns-fog-1.22.9 tests/libvirt/models/compute/interface_tests.rb
ns-fog-1.22.8 tests/libvirt/models/compute/interface_tests.rb
ns-fog-1.22.7 tests/libvirt/models/compute/interface_tests.rb
ns-fog-1.22.6 tests/libvirt/models/compute/interface_tests.rb
fog-1.23.0 tests/libvirt/models/compute/interface_tests.rb
ns-fog-1.22.4 tests/libvirt/models/compute/interface_tests.rb
ns-fog-1.22.3 tests/libvirt/models/compute/interface_tests.rb
ns-fog-1.22.2 tests/libvirt/models/compute/interface_tests.rb
fog-1.22.1 tests/libvirt/models/compute/interface_tests.rb