Sha256: 2b703fde1af20dd7df33367bd60ae21292758f36477580e192a5ebb287a3ecc4

Contents?: true

Size: 623 Bytes

Versions: 13

Compression:

Stored size: 623 Bytes

Contents

require 'spec_helper'

require 'vagrant-notify/action/prepare_data'

describe Vagrant::Notify::Action::PrepareData do
  let(:data_dir) { Pathname.new(Dir.mktmpdir) }
  let(:app)      { lambda { |env| } }
  let(:env)      { {machine: mock(data_dir: data_dir)} }

  subject { described_class.new(app, env) }

  before { subject.call(env) }
  after  { FileUtils.rm_rf data_dir.to_s }

  it 'creates the directory to keep vagrant notify data' do
    data_dir.join('vagrant-notify').should be_directory
  end

  it 'assigns a data object to the environment' do
    env[:notify_data].should be_a(Vagrant::Notify::Data)
  end
end

Version data entries

13 entries across 13 versions & 1 rubygems

Version Path
vagrant-notify-0.6.0 spec/action/prepare_data_spec.rb
vagrant-notify-0.5.6 spec/action/prepare_data_spec.rb
vagrant-notify-0.5.5 spec/action/prepare_data_spec.rb
vagrant-notify-0.5.4 spec/action/prepare_data_spec.rb
vagrant-notify-0.5.3 spec/action/prepare_data_spec.rb
vagrant-notify-0.5.2 spec/action/prepare_data_spec.rb
vagrant-notify-0.5.1 spec/action/prepare_data_spec.rb
vagrant-notify-0.5.0 spec/action/prepare_data_spec.rb
vagrant-notify-0.4.0 spec/action/prepare_data_spec.rb
vagrant-notify-0.3.0 spec/action/prepare_data_spec.rb
vagrant-notify-0.2.2 spec/action/prepare_data_spec.rb
vagrant-notify-0.2.1 spec/action/prepare_data_spec.rb
vagrant-notify-0.2.0 spec/action/prepare_data_spec.rb