From e25ac6e59711fa21200845327cafe07a1b4a4f25 Mon Sep 17 00:00:00 2001 From: Chris Koeritz Date: Thu, 10 May 2012 15:30:02 -0400 Subject: [PATCH] added a test for the shunit. not quite right though; feisty needs to set the SHUNIT_DIR variable. --- scripts/shunit/example_shunit_test.sh | 32 +++++++++++++++++++++++++++ 1 file changed, 32 insertions(+) create mode 100755 scripts/shunit/example_shunit_test.sh diff --git a/scripts/shunit/example_shunit_test.sh b/scripts/shunit/example_shunit_test.sh new file mode 100755 index 00000000..ab3e01c9 --- /dev/null +++ b/scripts/shunit/example_shunit_test.sh @@ -0,0 +1,32 @@ +#!/bin/bash + +# An example of using shunit2. +# +# Author: Chris Koeritz + +export WORKDIR="$( \cd "$(\dirname "$0")" && \pwd )" # obtain the script's working directory. +cd $WORKDIR + +SHUNIT_DIR=/home/fred/xsede/xsede_tests/shunit + +oneTimeSetUp() +{ + echo into set up. +} + +testOneThing() +{ + echo got to test case. + zero=0 + assertEquals "zero should be equal to 0" 0 $zero + sleep 23 +} + +oneTimeTearDown() +{ + echo into tear down. +} + +# load and run shUnit2 +source $SHUNIT_DIR/shunit2 + -- 2.34.1