2011-11-07 06:15:59 +00:00
|
|
|
require File.expand_path("../base", __FILE__)
|
2011-11-06 21:30:49 +00:00
|
|
|
|
2011-11-07 07:47:23 +00:00
|
|
|
describe "vagrant up", "basics" do
|
2011-11-09 07:03:15 +00:00
|
|
|
include_context "acceptance"
|
|
|
|
|
2011-11-07 07:47:23 +00:00
|
|
|
it "fails if not Vagrantfile is found" do
|
2011-11-07 02:23:06 +00:00
|
|
|
result = execute("vagrant", "up")
|
2011-11-09 07:03:15 +00:00
|
|
|
result.should_not be_success
|
|
|
|
result.stdout.should match_output(:no_vagrantfile)
|
2011-11-07 02:23:06 +00:00
|
|
|
end
|
|
|
|
|
2011-11-07 07:47:23 +00:00
|
|
|
it "brings up a running virtual machine" do
|
2011-11-06 21:30:49 +00:00
|
|
|
assert_execute("vagrant", "box", "add", "base", config.boxes["default"])
|
|
|
|
assert_execute("vagrant", "init")
|
|
|
|
assert_execute("vagrant", "up")
|
|
|
|
result = assert_execute("vagrant", "status")
|
2011-11-09 07:03:15 +00:00
|
|
|
result.stdout.should match_output(:status, "default", "running")
|
2011-11-06 21:30:49 +00:00
|
|
|
end
|
|
|
|
|
2011-11-07 02:27:31 +00:00
|
|
|
=begin
|
|
|
|
|
|
|
|
TODO:
|
|
|
|
|
|
|
|
should "be able to run if `Vagrantfile` is in parent directory"
|
|
|
|
should "bring up a running virtual machine and have a `/vagrant' shared folder by default"
|
|
|
|
should "destroy a running virtual machine"
|
|
|
|
should "save then restore a virtual machine using `vagrant up`"
|
|
|
|
should "halt then start a virtual machine using `vagrant up`"
|
|
|
|
|
2011-11-06 21:30:49 +00:00
|
|
|
=end
|
|
|
|
end
|