Fix rspec tests
This commit is contained in:
parent
d0d69e59c9
commit
42419bbd49
|
@ -1,5 +1,4 @@
|
|||
require "set"
|
||||
require 'pry'
|
||||
|
||||
require "vagrant/config/v2/util"
|
||||
|
||||
|
|
|
@ -1,5 +1,4 @@
|
|||
require "vagrant"
|
||||
require 'pry'
|
||||
|
||||
require_relative "ssh_connect"
|
||||
|
||||
|
|
|
@ -1,5 +1,4 @@
|
|||
require "vagrant"
|
||||
require 'pry'
|
||||
|
||||
require File.expand_path("../vm_trigger", __FILE__)
|
||||
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
require 'log4r'
|
||||
require 'pry'
|
||||
|
||||
require Vagrant.source_root.join('plugins/provisioners/shell/config')
|
||||
|
||||
module VagrantPlugins
|
||||
|
|
|
@ -5,20 +5,22 @@ require Vagrant.source_root.join("plugins/kernel_v2/config/vm_trigger")
|
|||
describe VagrantPlugins::Kernel_V2::VagrantConfigTrigger do
|
||||
include_context "unit"
|
||||
|
||||
subject { described_class.new }
|
||||
let(:command) { :up }
|
||||
|
||||
subject { described_class.new(command) }
|
||||
|
||||
let(:machine) { double("machine") }
|
||||
|
||||
def assert_invalid
|
||||
errors = subject.validate(machine)
|
||||
if !errors.values.any? { |v| !v.empty? }
|
||||
if !errors.empty? { |v| !v.empty? }
|
||||
raise "No errors: #{errors.inspect}"
|
||||
end
|
||||
end
|
||||
|
||||
def assert_valid
|
||||
errors = subject.validate(machine)
|
||||
if !errors.values.all? { |v| v.empty? }
|
||||
if !errors.empty? { |v| v.empty? }
|
||||
raise "Errors: #{errors.inspect}"
|
||||
end
|
||||
end
|
||||
|
|
Loading…
Reference in New Issue