Basic package acceptance tests

This commit is contained in:
Mitchell Hashimoto 2012-01-12 23:52:25 -08:00
parent 1927f8ef79
commit 1380bc6ae7
1 changed files with 23 additions and 0 deletions

View File

@ -0,0 +1,23 @@
require File.expand_path("../base", __FILE__)
require "acceptance/support/shared/command_examples"
describe "vagrant package" do
include_context "acceptance"
it_behaves_like "a command that requires a Vagrantfile", ["vagrant", "package"]
# This creates an initial environment that is ready for a "vagrant up"
def initialize_valid_environment
require_box("default")
assert_execute("vagrant", "box", "add", "base", box_path("default"))
assert_execute("vagrant", "init")
end
it "can package a running virtual machine" do
initialize_valid_environment
assert_execute("vagrant", "up")
assert_execute("vagrant", "package")
environment.workdir.join("package.box").should be_file
end
end