Sha256: 0476ca93a91e48330ee76c6d1e6df4883620edd75b5173cade916b69951c7f53

Contents?: true

Size: 866 Bytes

Versions: 21

Compression:

Stored size: 866 Bytes

Contents

# This tests that an instance can be reloaded correctly
shared_examples 'provider/reload' do |provider, options|
  unless options[:box]
    raise ArgumentError,
          "box option must be specified for provider: #{provider}"
  end

  include_context 'acceptance'

  before do
    environment.skeleton('generic')
    assert_execute('vagrant', 'box', 'add', 'basic', options[:box])
    assert_execute('vagrant', 'up', "--provider=#{provider}")
  end

  after do
    assert_execute('vagrant', 'destroy', '--force')
  end

  it 'should reload the machine correctly' do
    status("Test: machine can be reloaded")
    reload_result = execute("vagrant", "reload")
    expect(reload_result).to exit_with(0)

    echo_result = execute("vagrant", "ssh", "-c", "echo foo")
    expect(echo_result).to exit_with(0)
    expect(echo_result.stdout).to match(/foo\n$/)
  end
end

Version data entries

21 entries across 21 versions & 1 rubygems

Version Path
vagrant-google-2.7.0 test/acceptance/provider/reload_spec.rb
vagrant-google-2.6.0 test/acceptance/provider/reload_spec.rb
vagrant-google-2.5.0 test/acceptance/provider/reload_spec.rb
vagrant-google-2.4.0 test/acceptance/provider/reload_spec.rb
vagrant-google-2.4.0.rc0 test/acceptance/provider/reload_spec.rb
vagrant-google-2.3.0 test/acceptance/provider/reload_spec.rb
vagrant-google-2.3.0.rc0 test/acceptance/provider/reload_spec.rb
vagrant-google-2.2.1 test/acceptance/provider/reload_spec.rb
vagrant-google-2.2.0 test/acceptance/provider/reload_spec.rb
vagrant-google-2.2.0.rc0 test/acceptance/provider/reload_spec.rb
vagrant-google-2.1.0 test/acceptance/provider/reload_spec.rb
vagrant-google-2.0.0 test/acceptance/provider/reload_spec.rb
vagrant-google-2.0.0.rc1 test/acceptance/provider/reload_spec.rb
vagrant-google-2.0.0.rc0 test/acceptance/provider/reload_spec.rb
vagrant-google-1.0.0 test/acceptance/provider/reload_spec.rb
vagrant-google-1.0.0.rc0 test/acceptance/provider/reload_spec.rb
vagrant-google-0.2.5 test/acceptance/provider/reload_spec.rb
vagrant-google-0.2.5.rc0 test/acceptance/provider/reload_spec.rb
vagrant-google-0.2.4 test/acceptance/provider/reload_spec.rb
vagrant-google-0.2.3 test/acceptance/provider/reload_spec.rb