Sha256: 9acb17255e49aac653893574146db024a0f96d07583df669163192834251127e

Contents?: true

Size: 886 Bytes

Versions: 9

Compression:

Stored size: 886 Bytes

Contents

Shindo.tests("Fog::Ovirt::Compute.new | template model", ["ovirt"]) do
  templates = Fog::Ovirt::Compute.new.templates
  template = templates.last

  tests("The template model should") do
    tests("have the action") do
      test("reload") { template.respond_to? "reload" }
    end
    tests("have attributes") do
      model_attribute_hash = template.attributes
      attributes = %i[id name]

      tests("The template model should respond to") do
        attributes.each do |attribute|
          test(attribute.to_s) { template.respond_to? attribute }
        end
      end
      tests("The attributes hash should have key") do
        attributes.each do |attribute|
          test(attribute.to_s) { model_attribute_hash.key? attribute }
        end
      end
    end
    test("be a kind of Fog::Ovirt::Compute::Template") { template.is_a? Fog::Ovirt::Compute::Template }
  end
end

Version data entries

9 entries across 9 versions & 1 rubygems

Version Path
fog-ovirt-2.0.2 tests/ovirt/models/compute/template_tests.rb
fog-ovirt-2.0.1 tests/ovirt/models/compute/template_tests.rb
fog-ovirt-2.0.0 tests/ovirt/models/compute/template_tests.rb
fog-ovirt-1.2.5 tests/ovirt/models/compute/template_tests.rb
fog-ovirt-1.2.4 tests/ovirt/models/compute/template_tests.rb
fog-ovirt-1.2.3 tests/ovirt/models/compute/template_tests.rb
fog-ovirt-1.2.2 tests/ovirt/models/compute/template_tests.rb
fog-ovirt-1.2.1 tests/ovirt/models/compute/template_tests.rb
fog-ovirt-1.2.0 tests/ovirt/models/compute/template_tests.rb