summaryrefslogtreecommitdiff
path: root/ci
diff options
context:
space:
mode:
authorBryan McLellan <btm@opscode.com>2012-11-13 09:33:47 -0800
committerBryan McLellan <btm@opscode.com>2012-11-13 10:19:19 -0800
commitea28e343db64d9dbee57707e81e19342c2493365 (patch)
treed42b241c7fbd358277583116b8f1c7ef4a2929b2 /ci
parent04fb4c8fd275441e9d6d55273fffe3b349ac6cd4 (diff)
downloadchef-ea28e343db64d9dbee57707e81e19342c2493365.tar.gz
Place script in repo for running CI tests
Chef 10 and 11 differ in directory structure so lets add a script to ease that This also exposes our testing a bit so other people know what we are doing interally. This commit excludes the 'cd chef' step in 10-stable
Diffstat (limited to 'ci')
-rw-r--r--ci/jenkins_run_tests.bat5
-rwxr-xr-xci/jenkins_run_tests.sh9
2 files changed, 14 insertions, 0 deletions
diff --git a/ci/jenkins_run_tests.bat b/ci/jenkins_run_tests.bat
new file mode 100644
index 0000000000..7d3a2d7c0d
--- /dev/null
+++ b/ci/jenkins_run_tests.bat
@@ -0,0 +1,5 @@
+set PATH=C:\Ruby192\bin;%PATH%
+
+ruby -v
+call bundle install --binstubs --path vendor/bundle || ( call rm Gemfile.lock && call bundle install --binstubs --path vendor/bundle )
+ruby bin\rspec -r rspec_junit_formatter -f RspecJunitFormatter -o test.xml -f documentation spec/unit spec/functional
diff --git a/ci/jenkins_run_tests.sh b/ci/jenkins_run_tests.sh
new file mode 100755
index 0000000000..ce8e1934c9
--- /dev/null
+++ b/ci/jenkins_run_tests.sh
@@ -0,0 +1,9 @@
+#!/bin/bash
+
+export PATH=/usr/local/bin:$PATH
+
+ruby -v;
+# remove the Gemfile.lock and try again if bundler fails.
+# This should take care of Gemfile changes that result in "bad" bundles without forcing us to rebundle every time
+bundle install --binstubs --path vendor/bundle || ( rm Gemfile.lock && bundle install --binstubs --path vendor/bundle )
+bin/rspec -r rspec_junit_formatter -f RspecJunitFormatter -o test.xml -f documentation spec;