Sha256: 2d0cb3c97771f7c7393860230a8a46b088cabee1b71a7a511919d64a86dad16d

Contents?: true

Size: 762 Bytes

Versions: 38

Compression:

Stored size: 762 Bytes

Contents

require "pathname"
require "tmpdir"

require File.expand_path("../../../../base", __FILE__)

describe Vagrant::Action::Builtin::Message do
  let(:app) { lambda { |env| } }
  let(:env) { { ui: ui } }

  let(:ui)  { double("ui") }

  describe "#call" do
    it "outputs the given message" do
      subject = described_class.new(app, env, "foo")

      expect(ui).to receive(:output).with("foo").ordered
      expect(app).to receive(:call).with(env).ordered

      subject.call(env)
    end

    it "outputs the given message after the call" do
      subject = described_class.new(app, env, "foo", post: true)

      expect(app).to receive(:call).with(env).ordered
      expect(ui).to receive(:output).with("foo").ordered

      subject.call(env)
    end
  end
end

Version data entries

38 entries across 31 versions & 7 rubygems

Version Path
vagrant-aws-mkubenka-0.7.2.pre.9 vendor/bundle/ruby/2.3.0/bundler/gems/vagrant-5333e60e2d38/test/unit/vagrant/action/builtin/message_test.rb
vagrant-unbundled-1.9.5.1 test/unit/vagrant/action/builtin/message_test.rb
vagrant-unbundled-1.9.1.1 test/unit/vagrant/action/builtin/message_test.rb
vagrant-compose-yaml-0.1.3 vendor/bundle/ruby/2.2.0/bundler/gems/vagrant-dbb756c7b6da/test/unit/vagrant/action/builtin/message_test.rb
vagrant-compose-yaml-0.1.2 vendor/bundle/ruby/2.2.0/bundler/gems/vagrant-dbb756c7b6da/test/unit/vagrant/action/builtin/message_test.rb
vagrant-compose-yaml-0.1.1 vendor/bundle/ruby/2.2.0/bundler/gems/vagrant-dbb756c7b6da/test/unit/vagrant/action/builtin/message_test.rb
vagrant-compose-yaml-0.1.0 vendor/bundle/ruby/2.2.0/bundler/gems/vagrant-dbb756c7b6da/test/unit/vagrant/action/builtin/message_test.rb
vagrant-unbundled-1.8.5.2 test/unit/vagrant/action/builtin/message_test.rb
vagrant-unbundled-1.8.5.1 test/unit/vagrant/action/builtin/message_test.rb
vagrant-unbundled-1.8.4.2 test/unit/vagrant/action/builtin/message_test.rb
vagrant-unbundled-1.8.4.1 test/unit/vagrant/action/builtin/message_test.rb
vagrant-unbundled-1.8.1.2 test/unit/vagrant/action/builtin/message_test.rb
vagrant-unbundled-1.8.1.1 test/unit/vagrant/action/builtin/message_test.rb
vagrant-cloudstack-1.1.0 vendor/bundle/bundler/gems/vagrant-1cf2a8db4ccb/test/unit/vagrant/action/builtin/message_test.rb
vagrant-cloudstack-1.1.0 vendor/bundle/bundler/gems/vagrant-b421af58e8b3/test/unit/vagrant/action/builtin/message_test.rb
vagrant-cloudstack-1.1.0 vendor/bundle/bundler/gems/vagrant-309e896975d1/test/unit/vagrant/action/builtin/message_test.rb
vagrant-cloudstack-1.1.0 vendor/bundle/bundler/gems/vagrant-272fb27e0536/test/unit/vagrant/action/builtin/message_test.rb
vagrant-tiktalik-0.0.3 vendor/bundle/ruby/2.0.0/bundler/gems/vagrant-1e28f1ac31e7/test/unit/vagrant/action/builtin/message_test.rb