summaryrefslogtreecommitdiff
path: root/cpp/examples/verify_all
diff options
context:
space:
mode:
authorAlan Conway <aconway@apache.org>2008-05-14 16:24:08 +0000
committerAlan Conway <aconway@apache.org>2008-05-14 16:24:08 +0000
commit219664470d939b7f514fce3f0b6ce2ea9193ef7d (patch)
tree49424decbdfb2bb516926bfd44f1c4f97d52e461 /cpp/examples/verify_all
parentddb57760e7e3ec1ea54a8dfccd9b3087cbffb80a (diff)
downloadqpid-python-219664470d939b7f514fce3f0b6ce2ea9193ef7d.tar.gz
Exclude XML example checks if XML support is not available.
git-svn-id: https://svn.apache.org/repos/asf/incubator/qpid/trunk/qpid@656326 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'cpp/examples/verify_all')
-rwxr-xr-xcpp/examples/verify_all23
1 files changed, 17 insertions, 6 deletions
diff --git a/cpp/examples/verify_all b/cpp/examples/verify_all
index 427a46f5be..0fc1625355 100755
--- a/cpp/examples/verify_all
+++ b/cpp/examples/verify_all
@@ -2,16 +2,19 @@
# Verify all C++/python example combinations.
#
-srcdir=$1 ;
verify=`dirname $0`/verify
-qpidd=../src/qpidd
-python=$srcdir/python
-
+topdir=$1
+exclude_regexp=$2
+
+
+qpidd=$topdir/cpp/src/qpidd
+python=$topdir/python
+
trap "$qpidd -q" exit
export QPID_PORT=`$qpidd -dp0 --data-dir "" --auth no`
export PYTHON_EXAMPLES=$python/examples
export PYTHONPATH=$python:$PYTHONPATH
-export AMQP_SPEC=$srcdir/specs/amqp.0-10.xml
+export AMQP_SPEC=$topdir/specs/amqp.0-10.xml
test -d $PYTHON_EXAMPLES || echo "Warning: not verifying python examples, $PYTHON_EXAMPLES not found"
find="find examples"
@@ -19,5 +22,13 @@ test -d $PYTHON_EXAMPLES && find="$find $PYTHON_EXAMPLES"
find="$find -name verify"
test -d $PYTHON_EXAMPLES && \
find="$find -o -name verify_cpp_python -o -name verify_python_cpp"
-$verify `$find`
+all_examples=`$find`
+if test -z "$exclude_regexp"; then
+ run_examples=$all_examples
+else
+ for f in $all_examples; do
+ { cat $f | grep $exclude_regexp > /dev/null ; } || run_examples="$run_examples $f"
+ done
+fi
+$verify $run_examples