From 05c478baa94fe2731895a10ee63f20e3dfc78c3e Mon Sep 17 00:00:00 2001 From: Thomas Levine Date: Mon, 8 Oct 2012 08:50:48 -0400 Subject: [PATCH] meta-tests --- tests/setup | 1 + tests/teardown | 0 tests/test_something/fixtures/thingy | 0 tests/test_something/test_thing_exists | 0 urchin | 7 ++++++- 5 files changed, 7 insertions(+), 1 deletion(-) create mode 100644 tests/setup create mode 100644 tests/teardown create mode 100644 tests/test_something/fixtures/thingy create mode 100644 tests/test_something/test_thing_exists diff --git a/tests/setup b/tests/setup new file mode 100644 index 0000000..7b40fbd --- /dev/null +++ b/tests/setup @@ -0,0 +1 @@ +#urchin_export tmp=$(mktemp -d) diff --git a/tests/teardown b/tests/teardown new file mode 100644 index 0000000..e69de29 diff --git a/tests/test_something/fixtures/thingy b/tests/test_something/fixtures/thingy new file mode 100644 index 0000000..e69de29 diff --git a/tests/test_something/test_thing_exists b/tests/test_something/test_thing_exists new file mode 100644 index 0000000..e69de29 diff --git a/urchin b/urchin index ebb5b0d..c4f0fe9 100755 --- a/urchin +++ b/urchin @@ -7,7 +7,9 @@ recurse() { ( cd "$potential_test" [ -f setup ] && sh setup - ls test* | xargs recurse + for test in test* + do recurse "${test}" + done [ -f teardown ] && sh teardown ) elif [ -f "$potential_test" ] @@ -27,7 +29,10 @@ recurse() { if [ -d tests ] then + echo Running tests recurse tests + echo + echo Done else echo 'No tests directory' && exit 1 fi