get all the tests working with the new binary

This commit is contained in:
Thomas Reynolds 2011-07-26 23:19:43 -07:00
parent 4569d597f5
commit 2634c4156f
9 changed files with 46 additions and 27 deletions

View file

@ -1,15 +1,16 @@
require 'fileutils'
require 'middleman/cli'
Given /^a built test app$/ do
target = File.join(File.dirname(File.dirname(File.dirname(__FILE__))), "fixtures", "test-app")
build_cmd = File.expand_path(File.join(File.dirname(File.dirname(File.dirname(__FILE__))), "bin", "mm-build"))
`cd #{target} && MM_DIR="#{target}" #{build_cmd}`
build_cmd = File.expand_path(File.join(File.dirname(File.dirname(File.dirname(__FILE__))), "bin", "mm build"))
`cd #{target} && #{build_cmd}`
end
Given /^a built test app with flags "([^"]*)"$/ do |flags|
target = File.join(File.dirname(File.dirname(File.dirname(__FILE__))), "fixtures", "test-app")
build_cmd = File.expand_path(File.join(File.dirname(File.dirname(File.dirname(__FILE__))), "bin", "mm-build"))
`cd #{target} && MM_DIR="#{target}" #{build_cmd} #{flags}`
build_cmd = File.expand_path(File.join(File.dirname(File.dirname(File.dirname(__FILE__))), "bin", "mm build"))
`cd #{target} && #{build_cmd} #{flags}`
end
Given /^cleanup built test app$/ do