Sha256: 9e8d79204442d0afd0dad7a55c72c51ba5da314da0bff08c38ed25392ec1101c

Contents?: true

Size: 1.02 KB

Versions: 19

Compression:

Stored size: 1.02 KB

Contents

Given /the adapters are reset/ do
  VBoxManage.network_adapters(@output).each_with_index do |obj, i|
    VBoxManage.execute("modifyvm", @name, "--nic#{i+1}", "none")
  end
end

Given /the adapter in slot "(.+?)" is type "(.+?)"/ do |slot, type|
  VBoxManage.execute("modifyvm", @name, "--nic#{slot}", type)
end

Given /the following adapters are set:/ do |table|
  table.hashes.each do |hash|
    Given %Q[the adapter in slot "#{hash["slot"]}" is type "#{hash["type"]}"]
  end
end

When /I update the adapter in slot "(.+?)"/ do |slot|
  adapter = @relationship.find { |na| na.slot == (slot.to_i - 1) }
  adapter.should_not be_nil

  @model = adapter
end

Then /the network adapter properties should match/ do
  adapters = VBoxManage.network_adapters(@output)
  @relationship.length.should == adapters.length

  @relationship.each do |na|
    adapter = adapters[na.slot + 1]
    adapter.should_not be_nil

    if na.enabled?
      test_mappings(NETWORK_ADAPTER_MAPPINGS, na, adapter)
    else
      adapter[:type].should == "none"
    end
  end
end

Version data entries

19 entries across 19 versions & 3 rubygems

Version Path
virtualbox-0.9.2 features/step_definitions/network_adapter_steps.rb
virtualbox-0.9.1 features/step_definitions/network_adapter_steps.rb
virtualbox-0.9.0 features/step_definitions/network_adapter_steps.rb
virtualbox-0.8.6 features/step_definitions/network_adapter_steps.rb
virtualbox-0.8.5 features/step_definitions/network_adapter_steps.rb
virtualbox-0.8.4 features/step_definitions/network_adapter_steps.rb
velir_virtualbox-0.8.4 features/step_definitions/network_adapter_steps.rb
virtualbox-0.8.3 features/step_definitions/network_adapter_steps.rb
virtualbox-0.8.2 features/step_definitions/network_adapter_steps.rb
virtualbox-0.8.1 features/step_definitions/network_adapter_steps.rb
virtualbox-0.8.0 features/step_definitions/network_adapter_steps.rb
virtualbox-0.7.9 features/step_definitions/network_adapter_steps.rb
virtualbox-0.7.8 features/step_definitions/network_adapter_steps.rb
virtualbox-0.7.7 features/step_definitions/network_adapter_steps.rb
virtualbox-0.7.6 features/step_definitions/network_adapter_steps.rb
bbrowning-virtualbox-0.7.6.dev features/step_definitions/network_adapter_steps.rb
virtualbox-0.7.5 features/step_definitions/network_adapter_steps.rb
virtualbox-0.7.4 features/step_definitions/network_adapter_steps.rb
virtualbox-0.7.3 features/step_definitions/network_adapter_steps.rb