Sha256: c8a13c322fa5ac5a82fc110e5ec4bd9e71cbdf5eb5f565fd2a3089e2ca2c545a
Contents?: true
Size: 734 Bytes
Versions: 4
Compression:
Stored size: 734 Bytes
Contents
require "test_helper" class CommandsBoxListTest < Test::Unit::TestCase setup do @klass = Vagrant::Commands::Box::List @persisted_vm = mock("persisted_vm") @persisted_vm.stubs(:execute!) @env = mock_environment @env.stubs(:require_persisted_vm) @env.stubs(:vm).returns(@persisted_vm) @instance = @klass.new(@env) end context "executing" do setup do @boxes = ["foo", "bar"] Vagrant::Box.stubs(:all).returns(@boxes) @instance.stubs(:wrap_output) end should "call all on box and sort the results" do @all = mock("all") @all.expects(:sort).returns(@boxes) Vagrant::Box.expects(:all).with(@env).returns(@all) @instance.execute end end end
Version data entries
4 entries across 4 versions & 2 rubygems