summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRoland Grunberg <rgrunber@redhat.com>2013-08-09 10:35:40 -0400
committerRoland Grunberg <rgrunber@redhat.com>2013-08-09 13:33:33 -0400
commit57644f1550f079484653eae3754fea037e13d832 (patch)
tree8bc9f670c08880fa279907eb6b59145436e8fac8
parentf9a71ca6994a9e9fa7e29451f91fbf4445e53cf7 (diff)
downloadtycho-surefire-testbundlerunner-57644f1550f079484653eae3754fea037e13d832.tar.gz
tycho-surefire-testbundlerunner-57644f1550f079484653eae3754fea037e13d832.tar.xz
tycho-surefire-testbundlerunner-57644f1550f079484653eae3754fea037e13d832.zip
Add some error checking and fix comments.
-rwxr-xr-xprepTestBundle.sh8
-rwxr-xr-xrunAllTestBundles.sh9
2 files changed, 14 insertions, 3 deletions
diff --git a/prepTestBundle.sh b/prepTestBundle.sh
index be704d2..0271c62 100755
--- a/prepTestBundle.sh
+++ b/prepTestBundle.sh
@@ -13,9 +13,10 @@
# org.eclipse.tycho:org.eclipse.tycho.surefire.testbundlerunner
# | plugin:tycho-maven-plugin
# | plugin:target-platform-configuration
+# | plugin:tycho-surefire-plugin (pluginManagement)
# |
# --> osgiTestBundle (gid:aid)
-# plugin:tycho-surefire-plugin
+# plugin:tycho-surefire-plugin (may inherit)
# File System Conceptual Layout
@@ -29,6 +30,11 @@
# --> target/classes/**.class
# --> resources/
+if [ ! $# -eq 1 ]; then
+ echo "USAGE : $0 /PATH/TO/JAR"
+ exit 1
+fi
+
jarLoc=$1
jarPomPath=`jar -tf ${jarLoc} | grep 'pom.xml'`
diff --git a/runAllTestBundles.sh b/runAllTestBundles.sh
index d5a2d10..97564d6 100755
--- a/runAllTestBundles.sh
+++ b/runAllTestBundles.sh
@@ -14,11 +14,16 @@
# Takes a single argument (absolute path of folder containing test bundles)
+if [ ! $# -eq 1 ]; then
+ echo "USAGE : $0 PATH/TO/BUNDLES/DIRECTORY"
+ exit 1
+fi
+
testBundleFolder=$1
for jar in `find ${testBundleFolder} -name "*.jar"`; do
- jarPomPath=`jar -tf ${jar} | grep 'pom.xml'`
- unzip -p ${jar} ${jarPomPath} | grep -q '<packaging>eclipse-test-plugin</packaging>' && ./prepTestBundle.sh ${jar}
+ jarPomPath=`jar -tf ${jar} | grep 'pom.xml'`
+ unzip -p ${jar} ${jarPomPath} | grep -q '<packaging>eclipse-test-plugin</packaging>' && ./prepTestBundle.sh ${jar}
done
mvn-rpmbuild -fae -DskipTychoVersionCheck org.eclipse.tycho:tycho-surefire-plugin:test