mirror of
https://github.com/wahyd4/gvm.git
synced 2026-08-09 04:46:19 +10:00
Add some new tests
This commit is contained in:
@@ -10,3 +10,18 @@ task :default do
|
||||
Process.waitpid(pid)
|
||||
end
|
||||
end
|
||||
|
||||
task :scenario do
|
||||
root_path = File.expand_path "../.", __FILE__
|
||||
Dir["#{root_path}/tests/scenario/*_comment_test.sh"].each do |test|
|
||||
name = File.basename(test)
|
||||
puts "Running scenario #{name}..."
|
||||
Dir.mktmpdir("gvm-test") do |tmpdir|
|
||||
install = `binscripts/gvm-installer binary_default #{tmpdir}`
|
||||
pid = fork do
|
||||
exec("bash -c 'source #{tmpdir}/gvm/scripts/gvm; tf --text #{tmpdir}/gvm/tests/scenario/#{name}'")
|
||||
end
|
||||
Process.waitpid(pid)
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
@@ -0,0 +1 @@
|
||||
gvm install go1.2.2 --binary #status=0
|
||||
@@ -0,0 +1 @@
|
||||
gvm install go1.2.2 #status=0
|
||||
Reference in New Issue
Block a user