Use lttng-consumerd of the code tree for tests
authorDavid Goulet <dgoulet@efficios.com>
Tue, 31 Jan 2012 15:47:54 +0000 (10:47 -0500)
committerDavid Goulet <dgoulet@efficios.com>
Tue, 31 Jan 2012 16:41:32 +0000 (11:41 -0500)
Better use the consumer daemon in tree that we just built and not the
one installed on the system that might be quite old ;)

Signed-off-by: David Goulet <dgoulet@efficios.com>
tests/utils.sh

index 01e8eae21b3886c0bd532f0e438610e94e74c8cf..55bc9e9d5a41adf559840f41a0bab677c25894db 100644 (file)
@@ -41,15 +41,16 @@ function validate_kernel_version ()
 
 function start_sessiond ()
 {
+       echo ""
+       echo -n "Starting session daemon... "
        validate_kernel_version
        if [ $? -ne 0 ]; then
                echo -e "\n*** Kernel to old for session daemon tests ***\n"
                return 2
        fi
 
-       if [ -z $(pidof $SESSIOND_BIN) ]; then
-               echo -n "Starting session daemon... "
-               $TESTDIR/../src/bin/lttng-sessiond/$SESSIOND_BIN --daemonize --quiet
+       if [ -z $(pidof lt-$SESSIOND_BIN) ]; then
+               $TESTDIR/../src/bin/lttng-sessiond/$SESSIOND_BIN --daemonize --quiet --consumerd32-path="$(pwd)/../src/bin/lttng-consumerd/lttng-consumerd" --consumerd64-path="$(pwd)/../src/bin/lttng-consumerd/lttng-consumerd"
                if [ $? -eq 1 ]; then
                        echo -e "\e[1;31mFAILED\e[0m"
                        return 1
@@ -154,6 +155,12 @@ function trace_matches ()
        nr_iter=$2
        trace_path=$3
 
+       which $BABELTRACE_BIN >/dev/null
+       if [ $? -eq 1 ]; then
+               echo "Babeltrace binary not found. Skipping trace matches"
+               return 0
+       fi
+
        echo -n "Looking for $nr_iter $event_name in $trace_path "
 
        count=$($BABELTRACE_BIN $trace_path | grep $event_name | wc -l)
This page took 0.025879 seconds and 4 git commands to generate.