diff options
author | Roland Grunberg <rgrunber@redhat.com> | 2013-08-09 10:35:40 -0400 |
---|---|---|
committer | Roland Grunberg <rgrunber@redhat.com> | 2013-08-09 13:33:33 -0400 |
commit | 57644f1550f079484653eae3754fea037e13d832 (patch) | |
tree | 8bc9f670c08880fa279907eb6b59145436e8fac8 | |
parent | f9a71ca6994a9e9fa7e29451f91fbf4445e53cf7 (diff) | |
download | tycho-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-x | prepTestBundle.sh | 8 | ||||
-rwxr-xr-x | runAllTestBundles.sh | 9 |
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 |