Sha256: 9b30049cde10d67b8edd8ed5af304f437363ee3158b7d64f601aee3b59d74865

Contents?: true

Size: 1.05 KB

Versions: 9

Compression:

Stored size: 1.05 KB

Contents

require 'spec_helper'

shared_context 'unit' do
  include_context 'vagrant-unit'

  let(:vagrantfile) do
    <<-EOF
    Vagrant.configure('2') do |config|
      config.vm.define :test
    end
    EOF
  end
  let(:test_env) do
    test_env = isolated_environment
    test_env.vagrantfile vagrantfile
    test_env
  end
  let(:env)              { { env: iso_env, machine: machine, ui: ui, root_path: '/rootpath' } }
  let(:conf)             { Vagrant::Config::V2::DummyConfig.new }
  let(:ui)               { Vagrant::UI::Basic.new }
  let(:iso_env)          { test_env.create_vagrant_env ui_class: Vagrant::UI::Basic }
  let(:machine)          { iso_env.machine(:test, :libvirt) }
  # Mock the communicator to prevent SSH commands for being executed.
  let(:communicator)     { double('communicator') }
  # Mock the guest operating system.
  let(:guest)            { double('guest') }
  let(:app)              { ->(env) {} }
  let(:plugin)           { register_plugin }

  before (:each) do
    machine.stub(guest: guest)
    machine.stub(communicator: communicator)
  end
end

Version data entries

9 entries across 9 versions & 1 rubygems

Version Path
vagrant-libvirt-0.1.2 spec/support/sharedcontext.rb
vagrant-libvirt-0.1.0 spec/support/sharedcontext.rb
vagrant-libvirt-0.0.45 spec/support/sharedcontext.rb
vagrant-libvirt-0.0.43 spec/support/sharedcontext.rb
vagrant-libvirt-0.0.42 spec/support/sharedcontext.rb
vagrant-libvirt-0.0.40 spec/support/sharedcontext.rb
vagrant-libvirt-0.0.39 spec/support/sharedcontext.rb
vagrant-libvirt-0.0.38 spec/support/sharedcontext.rb
vagrant-libvirt-0.0.37 spec/support/sharedcontext.rb