Added option to run a specific feature

This commit is contained in:
Will Daly
2013-05-10 10:35:51 -04:00
parent 2546d6227f
commit 881b72a6d1

View File

@@ -243,9 +243,9 @@ def run_tests(system, report_dir, stop_on_failure=true)
end
end
def run_acceptance_tests(system, report_dir)
def run_acceptance_tests(system, report_dir, feature_path)
ENV['NOSE_XUNIT_FILE'] = File.join(report_dir, 'acceptance_tests.xml')
sh(django_admin(system, 'acceptance', 'harvest', '--debug-mode'))
sh(django_admin(system, 'acceptance', 'harvest', '--debug-mode', feature_path))
end
@@ -273,8 +273,9 @@ end
# Run acceptance tests
desc "Run acceptance tests"
task "test_acceptance" => ["clean_test_files", "#{system}:gather_assets:acceptance", :predjango, report_dir] do
run_acceptance_tests(system, report_dir)
task "test_acceptance", [:feature_path] => ["clean_test_files", :predjango, report_dir] do |t, args|
args.with_defaults(:feature_path => '')
run_acceptance_tests(system, report_dir, args.feature_path)
end
task :fasttest => "fasttest_#{system}"