Permalink
Browse files

Fix a test to call N/A on other OSes

  • Loading branch information...
1 parent c461779 commit 89f5360e9cc448e796bc83f3798ee422bfd5cf76 @jes5199 committed Jul 8, 2010
Showing with 16 additions and 6 deletions.
  1. +2 −2 puppet_spec.sh
  2. +1 −1 spec/drivers.sh
  3. +5 −1 spec/resource/service/ticket_4123_should_list_all_running_redhat_spec.sh
  4. +2 −2 spec/setup.sh
  5. +6 −0 spec/util.sh
View
4 puppet_spec.sh
@@ -23,7 +23,7 @@ touch $FAIL_LOG
for SPEC in `find $TEST_DIR -name '*_spec.sh' ` ; do
if ! [ -x $SPEC ] ; then
- echo -n P
+ echo -n p
let "PENDING+=1"
continue
fi
@@ -32,7 +32,7 @@ for SPEC in `find $TEST_DIR -name '*_spec.sh' ` ; do
else
let TEST_ERROR=$?
if [ $TEST_ERROR -eq 11 ] ; then
- echo -n -
+ echo -n ~
let "SKIPPED+=1"
else
echo $SPEC >> $FAIL_LOG
View
2 spec/drivers.sh
@@ -1,5 +1,5 @@
#!/bin/bash
-. `dirname $0`/util.sh
+. spec/util.sh
function driver_standalone {
function execute_manifest {
View
6 spec/resource/service/ticket_4123_should_list_all_running_redhat_spec.sh
@@ -1,6 +1,10 @@
#!/bin/bash
-. local_setup.sh
+. spec/setup.sh
+
+if [ `facter operatingsystem` != "Redhat" ] ; then NOT_APPLICABLE ; fi
+
+
#
# this test is prone to failures because it uses process lookup to determine failures.
#
View
4 spec/setup.sh
@@ -1,5 +1,5 @@
#!/bin/bash
-. `dirname $0`/drivers.sh
+. spec/drivers.sh
env_driver
-. `dirname $0`/../local_setup.sh
+. local_setup.sh
View
6 spec/util.sh
@@ -1,3 +1,5 @@
+#!/bin/bash
+
function start_puppet_agent {
MASTER_PORT=18140
$BIN/puppet agent --vardir /tmp/puppet-$$-agent --confdir /tmp/puppet-$$-agent --rundir /tmp/puppet-$$-agent \
@@ -54,3 +56,7 @@ function start_puppetmasterd {
function stop_puppetmasterd {
kill $MASTER_PID
}
+
+function NOT_APPLICABLE {
+ exit 11
+}

0 comments on commit 89f5360

Please sign in to comment.