Tests: Rename the UST tests runners to test_<test name>
authorChristian Babeux <christian.babeux@efficios.com>
Fri, 22 Feb 2013 03:26:41 +0000 (22:26 -0500)
committerChristian Babeux <christian.babeux@efficios.com>
Fri, 22 Feb 2013 18:00:27 +0000 (13:00 -0500)
Signed-off-by: Christian Babeux <christian.babeux@efficios.com>
19 files changed:
tests/regression/ust/before-after/Makefile.am
tests/regression/ust/before-after/run [deleted file]
tests/regression/ust/before-after/test_before_after [new file with mode: 0755]
tests/regression/ust/high-throughput/Makefile.am
tests/regression/ust/high-throughput/run [deleted file]
tests/regression/ust/high-throughput/test_high_throughput [new file with mode: 0755]
tests/regression/ust/low-throughput/Makefile.am
tests/regression/ust/low-throughput/run [deleted file]
tests/regression/ust/low-throughput/test_low_throughput [new file with mode: 0755]
tests/regression/ust/multi-session/Makefile.am
tests/regression/ust/multi-session/run [deleted file]
tests/regression/ust/multi-session/test_multi_session [new file with mode: 0755]
tests/regression/ust/nprocesses/Makefile.am
tests/regression/ust/nprocesses/run [deleted file]
tests/regression/ust/nprocesses/test_nprocesses [new file with mode: 0755]
tests/regression/ust/overlap/Makefile.am
tests/regression/ust/overlap/run [deleted file]
tests/regression/ust/overlap/test_overlap [new file with mode: 0755]
tests/regression/ust/runall.sh

index d197d72f517de698c0773f57b0a2f0f9bd1bbda1..f883a32706865a7f1d11ba67ea8ccd68291638da 100644 (file)
@@ -12,5 +12,5 @@ noinst_PROGRAMS = gen-nevents
 gen_nevents_SOURCES = gen-nevents.c tp.c ust_gen_nevents.h
 gen_nevents_LDADD = -llttng-ust
 
-noinst_SCRIPTS = run
-EXTRA_DIST = run
+noinst_SCRIPTS = test_before_after
+EXTRA_DIST = test_before_after
diff --git a/tests/regression/ust/before-after/run b/tests/regression/ust/before-after/run
deleted file mode 100755 (executable)
index cb1f8c2..0000000
+++ /dev/null
@@ -1,120 +0,0 @@
-#!/bin/bash
-#
-# Copyright (C) - 2012 David Goulet <dgoulet@efficios.com>
-#
-# This library is free software; you can redistribute it and/or modify it under
-# the terms of the GNU Lesser General Public License as published by the Free
-# Software Foundation; version 2.1 of the License.
-#
-# This library is distributed in the hope that it will be useful, but WITHOUT
-# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
-# FOR A PARTICULAR PURPOSE.  See the GNU Lesser General Public License for more
-# details.
-#
-# You should have received a copy of the GNU Lesser General Public License
-# along with this library; if not, write to the Free Software Foundation, Inc.,
-# 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301 USA
-TEST_DESC="UST tracer - Start tracing before and after execution"
-
-CURDIR=$(dirname $0)/
-TESTDIR=$CURDIR/../../..
-NR_ITER=100
-SESSION_NAME="per-session"
-EVENT_NAME="ust_gen_nevents:tptest"
-
-source $TESTDIR/utils/utils.sh
-
-print_test_banner "$TEST_DESC"
-
-if [ ! -x "$CURDIR/gen-nevents" ]; then
-       echo -e "No UST nevents binary detected. Passing."
-       exit 0
-fi
-
-# MUST set TESTDIR before calling those functions
-
-test_before_apps() {
-       local out
-
-       # BEFORE application is spawned
-       create_lttng_session $SESSION_NAME $TRACE_PATH
-       enable_ust_lttng_event $SESSION_NAME $EVENT_NAME
-       start_lttng_tracing $SESSION_NAME
-       # Start test
-       echo -n "Starting application... "
-       ./$CURDIR/gen-nevents $NR_ITER
-       echo -n "Ended "
-       print_ok
-       stop_lttng_tracing $SESSION_NAME
-       destroy_lttng_session $SESSION_NAME
-
-       trace_matches $EVENT_NAME $NR_ITER $TRACE_PATH
-
-       return $?
-}
-
-test_after_apps() {
-       local out
-
-       echo -n "Starting application... "
-       ./$CURDIR/gen-nevents 100 &
-       print_ok
-
-       # BEFORE application is spawned
-       create_lttng_session $SESSION_NAME $TRACE_PATH
-       enable_ust_lttng_event $SESSION_NAME $EVENT_NAME
-       start_lttng_tracing $SESSION_NAME
-
-       # At least hit one event
-       sleep 2
-
-       stop_lttng_tracing $SESSION_NAME
-       destroy_lttng_session $SESSION_NAME
-
-       out=$(babeltrace $TRACE_PATH | grep $EVENT_NAME | wc -l)
-       if [ $out -eq 0 ]; then
-               echo -n "No event found. Suppose to have at least one... "
-               print_fail
-               out=1
-       else
-               echo -n "Found $out event(s). Coherent... "
-               print_ok
-               out=0
-       fi
-
-       return $out
-}
-
-# MUST set TESTDIR before calling those functions
-
-start_lttng_sessiond
-
-echo ""
-echo "=== Start application BEFORE tracing was started ==="
-
-TRACE_PATH=$(mktemp -d)
-
-test_before_apps
-out=$?
-if [ $out -ne 0 ]; then
-       stop_lttng_sessiond
-       exit $out
-fi
-
-rm -rf $TRACE_PATH
-
-echo ""
-echo "=== Start application AFTER tracing was started ==="
-
-TRACE_PATH=$(mktemp -d)
-
-test_after_apps
-out=$?
-if [ $out -ne 0 ]; then
-       stop_lttng_sessiond
-       exit $out
-fi
-
-stop_lttng_sessiond
-
-rm -rf $TRACE_PATH
diff --git a/tests/regression/ust/before-after/test_before_after b/tests/regression/ust/before-after/test_before_after
new file mode 100755 (executable)
index 0000000..cb1f8c2
--- /dev/null
@@ -0,0 +1,120 @@
+#!/bin/bash
+#
+# Copyright (C) - 2012 David Goulet <dgoulet@efficios.com>
+#
+# This library is free software; you can redistribute it and/or modify it under
+# the terms of the GNU Lesser General Public License as published by the Free
+# Software Foundation; version 2.1 of the License.
+#
+# This library is distributed in the hope that it will be useful, but WITHOUT
+# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
+# FOR A PARTICULAR PURPOSE.  See the GNU Lesser General Public License for more
+# details.
+#
+# You should have received a copy of the GNU Lesser General Public License
+# along with this library; if not, write to the Free Software Foundation, Inc.,
+# 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301 USA
+TEST_DESC="UST tracer - Start tracing before and after execution"
+
+CURDIR=$(dirname $0)/
+TESTDIR=$CURDIR/../../..
+NR_ITER=100
+SESSION_NAME="per-session"
+EVENT_NAME="ust_gen_nevents:tptest"
+
+source $TESTDIR/utils/utils.sh
+
+print_test_banner "$TEST_DESC"
+
+if [ ! -x "$CURDIR/gen-nevents" ]; then
+       echo -e "No UST nevents binary detected. Passing."
+       exit 0
+fi
+
+# MUST set TESTDIR before calling those functions
+
+test_before_apps() {
+       local out
+
+       # BEFORE application is spawned
+       create_lttng_session $SESSION_NAME $TRACE_PATH
+       enable_ust_lttng_event $SESSION_NAME $EVENT_NAME
+       start_lttng_tracing $SESSION_NAME
+       # Start test
+       echo -n "Starting application... "
+       ./$CURDIR/gen-nevents $NR_ITER
+       echo -n "Ended "
+       print_ok
+       stop_lttng_tracing $SESSION_NAME
+       destroy_lttng_session $SESSION_NAME
+
+       trace_matches $EVENT_NAME $NR_ITER $TRACE_PATH
+
+       return $?
+}
+
+test_after_apps() {
+       local out
+
+       echo -n "Starting application... "
+       ./$CURDIR/gen-nevents 100 &
+       print_ok
+
+       # BEFORE application is spawned
+       create_lttng_session $SESSION_NAME $TRACE_PATH
+       enable_ust_lttng_event $SESSION_NAME $EVENT_NAME
+       start_lttng_tracing $SESSION_NAME
+
+       # At least hit one event
+       sleep 2
+
+       stop_lttng_tracing $SESSION_NAME
+       destroy_lttng_session $SESSION_NAME
+
+       out=$(babeltrace $TRACE_PATH | grep $EVENT_NAME | wc -l)
+       if [ $out -eq 0 ]; then
+               echo -n "No event found. Suppose to have at least one... "
+               print_fail
+               out=1
+       else
+               echo -n "Found $out event(s). Coherent... "
+               print_ok
+               out=0
+       fi
+
+       return $out
+}
+
+# MUST set TESTDIR before calling those functions
+
+start_lttng_sessiond
+
+echo ""
+echo "=== Start application BEFORE tracing was started ==="
+
+TRACE_PATH=$(mktemp -d)
+
+test_before_apps
+out=$?
+if [ $out -ne 0 ]; then
+       stop_lttng_sessiond
+       exit $out
+fi
+
+rm -rf $TRACE_PATH
+
+echo ""
+echo "=== Start application AFTER tracing was started ==="
+
+TRACE_PATH=$(mktemp -d)
+
+test_after_apps
+out=$?
+if [ $out -ne 0 ]; then
+       stop_lttng_sessiond
+       exit $out
+fi
+
+stop_lttng_sessiond
+
+rm -rf $TRACE_PATH
index cff8fe423051fb8c9f06e7a49ecf730a03d17d6d..544640469df393feb7ed069564767311a615fe9f 100644 (file)
@@ -12,5 +12,5 @@ noinst_PROGRAMS = gen-events
 gen_events_SOURCES = main.c tp.c tp.h
 gen_events_LDADD = -llttng-ust
 
-noinst_SCRIPTS = run
-EXTRA_DIST = run
+noinst_SCRIPTS = test_high_throughput
+EXTRA_DIST = test_high_throughput
diff --git a/tests/regression/ust/high-throughput/run b/tests/regression/ust/high-throughput/run
deleted file mode 100755 (executable)
index 5506073..0000000
+++ /dev/null
@@ -1,94 +0,0 @@
-#!/bin/bash
-#
-# Copyright (C) - 2012 David Goulet <dgoulet@efficios.com>
-#
-# This library is free software; you can redistribute it and/or modify it under
-# the terms of the GNU Lesser General Public License as published by the Free
-# Software Foundation; version 2.1 of the License.
-#
-# This library is distributed in the hope that it will be useful, but WITHOUT
-# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
-# FOR A PARTICULAR PURPOSE.  See the GNU Lesser General Public License for more
-# details.
-#
-# You should have received a copy of the GNU Lesser General Public License
-# along with this library; if not, write to the Free Software Foundation, Inc.,
-# 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301 USA
-TEST_DESC="UST tracer - Testing high events throughput"
-
-CURDIR=$(dirname $0)/
-TESTDIR=$CURDIR/../../..
-NR_ITER=20
-BIN_NAME="gen-events"
-SESSION_NAME="high-throughput"
-EVENT_NAME="tp:tptest"
-
-source $TESTDIR/utils/utils.sh
-
-print_test_banner "$TEST_DESC"
-
-if [ ! -x "$CURDIR/$BIN_NAME" ]; then
-       echo -e "No UST nevents binary detected. Passing."
-       exit 0
-fi
-
-TRACE_PATH=$(mktemp -d)
-
-# MUST set TESTDIR before calling those functions
-
-start_lttng_sessiond
-
-create_lttng_session $SESSION_NAME $TRACE_PATH
-
-enable_ust_lttng_event $SESSION_NAME $EVENT_NAME
-start_lttng_tracing $SESSION_NAME
-
-for i in `seq 1 $NR_ITER`; do
-       ./$CURDIR/$BIN_NAME & >/dev/null 2>&1
-done
-
-echo "Waiting for applications to end"
-while [ -n "$(pidof $BIN_NAME)" ]; do
-       echo -n "."
-       sleep 0.5
-done
-echo ""
-
-stop_lttng_tracing $SESSION_NAME
-destroy_lttng_session $SESSION_NAME
-
-stop_lttng_sessiond
-
-# Validate test
-
-TEMP_FILE=$(mktemp)
-TEMP_FILE_2=$(mktemp)
-
-traced=$(babeltrace $TRACE_PATH 2>/dev/null | wc -l)
-babeltrace $TRACE_PATH >/dev/null 2>$TEMP_FILE_2
-
-cat $TEMP_FILE_2 | cut -f4 -d " " >$TEMP_FILE
-
-dropped=0
-while read line;
-do
-       let dropped=$dropped+$line
-done < $TEMP_FILE
-
-let total=$dropped+$traced
-let wanted=$NR_ITER*1000000
-
-if [ $wanted -ne $total ]; then
-       echo -n "Expected $wanted. Dropped $dropped. Recorded $traced. Total $total... "
-       print_fail
-       out=1
-else
-       echo -n "Expected $wanted. Dropped $dropped. Recorded $traced. Total $total... "
-       print_ok
-       out=0
-fi
-
-rm -rf $TRACE_PATH
-rm $TEMP_FILE $TEMP_FILE_2
-
-exit $out
diff --git a/tests/regression/ust/high-throughput/test_high_throughput b/tests/regression/ust/high-throughput/test_high_throughput
new file mode 100755 (executable)
index 0000000..5506073
--- /dev/null
@@ -0,0 +1,94 @@
+#!/bin/bash
+#
+# Copyright (C) - 2012 David Goulet <dgoulet@efficios.com>
+#
+# This library is free software; you can redistribute it and/or modify it under
+# the terms of the GNU Lesser General Public License as published by the Free
+# Software Foundation; version 2.1 of the License.
+#
+# This library is distributed in the hope that it will be useful, but WITHOUT
+# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
+# FOR A PARTICULAR PURPOSE.  See the GNU Lesser General Public License for more
+# details.
+#
+# You should have received a copy of the GNU Lesser General Public License
+# along with this library; if not, write to the Free Software Foundation, Inc.,
+# 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301 USA
+TEST_DESC="UST tracer - Testing high events throughput"
+
+CURDIR=$(dirname $0)/
+TESTDIR=$CURDIR/../../..
+NR_ITER=20
+BIN_NAME="gen-events"
+SESSION_NAME="high-throughput"
+EVENT_NAME="tp:tptest"
+
+source $TESTDIR/utils/utils.sh
+
+print_test_banner "$TEST_DESC"
+
+if [ ! -x "$CURDIR/$BIN_NAME" ]; then
+       echo -e "No UST nevents binary detected. Passing."
+       exit 0
+fi
+
+TRACE_PATH=$(mktemp -d)
+
+# MUST set TESTDIR before calling those functions
+
+start_lttng_sessiond
+
+create_lttng_session $SESSION_NAME $TRACE_PATH
+
+enable_ust_lttng_event $SESSION_NAME $EVENT_NAME
+start_lttng_tracing $SESSION_NAME
+
+for i in `seq 1 $NR_ITER`; do
+       ./$CURDIR/$BIN_NAME & >/dev/null 2>&1
+done
+
+echo "Waiting for applications to end"
+while [ -n "$(pidof $BIN_NAME)" ]; do
+       echo -n "."
+       sleep 0.5
+done
+echo ""
+
+stop_lttng_tracing $SESSION_NAME
+destroy_lttng_session $SESSION_NAME
+
+stop_lttng_sessiond
+
+# Validate test
+
+TEMP_FILE=$(mktemp)
+TEMP_FILE_2=$(mktemp)
+
+traced=$(babeltrace $TRACE_PATH 2>/dev/null | wc -l)
+babeltrace $TRACE_PATH >/dev/null 2>$TEMP_FILE_2
+
+cat $TEMP_FILE_2 | cut -f4 -d " " >$TEMP_FILE
+
+dropped=0
+while read line;
+do
+       let dropped=$dropped+$line
+done < $TEMP_FILE
+
+let total=$dropped+$traced
+let wanted=$NR_ITER*1000000
+
+if [ $wanted -ne $total ]; then
+       echo -n "Expected $wanted. Dropped $dropped. Recorded $traced. Total $total... "
+       print_fail
+       out=1
+else
+       echo -n "Expected $wanted. Dropped $dropped. Recorded $traced. Total $total... "
+       print_ok
+       out=0
+fi
+
+rm -rf $TRACE_PATH
+rm $TEMP_FILE $TEMP_FILE_2
+
+exit $out
index a1df9f5e2600dcd8304b4beae25cb43d2f347feb..e62706007a2b097af442fc6adbe676cfe58e8ee6 100644 (file)
@@ -12,5 +12,5 @@ noinst_PROGRAMS = gen-events
 gen_events_SOURCES = main.c tp.c tp.h
 gen_events_LDADD = -llttng-ust -lurcu
 
-noinst_SCRIPTS = run
-EXTRA_DIST = run
+noinst_SCRIPTS = test_low_throughput
+EXTRA_DIST = test_low_throughput
diff --git a/tests/regression/ust/low-throughput/run b/tests/regression/ust/low-throughput/run
deleted file mode 100755 (executable)
index 2e11133..0000000
+++ /dev/null
@@ -1,101 +0,0 @@
-#!/bin/bash
-#
-# Copyright (C) - 2012 David Goulet <dgoulet@efficios.com>
-#
-# This library is free software; you can redistribute it and/or modify it under
-# the terms of the GNU Lesser General Public License as published by the Free
-# Software Foundation; version 2.1 of the License.
-#
-# This library is distributed in the hope that it will be useful, but WITHOUT
-# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
-# FOR A PARTICULAR PURPOSE.  See the GNU Lesser General Public License for more
-# details.
-#
-# You should have received a copy of the GNU Lesser General Public License
-# along with this library; if not, write to the Free Software Foundation, Inc.,
-# 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301 USA
-TEST_DESC="UST tracer - Testing low events throughput"
-
-CURDIR=$(dirname $0)/
-TESTDIR=$CURDIR/../../..
-BIN_NAME="gen-events"
-SESSION_NAME="low-throughput"
-EVENT_NAME="tp:slow"
-
-source $TESTDIR/utils/utils.sh
-
-print_test_banner "$TEST_DESC"
-
-if [ ! -x "$CURDIR/$BIN_NAME" ]; then
-       echo -e "No UST nevents binary detected. Passing."
-       exit 0
-fi
-
-TRACE_PATH=$(mktemp -d)
-
-# MUST set TESTDIR before calling those functions
-
-start_lttng_sessiond
-
-create_lttng_session $SESSION_NAME $TRACE_PATH
-
-enable_ust_lttng_event $SESSION_NAME $EVENT_NAME
-start_lttng_tracing $SESSION_NAME
-
-# This is going to take 20 minutes
-./$CURDIR/$BIN_NAME >/dev/null 2>&1
-
-stop_lttng_tracing $SESSION_NAME
-destroy_lttng_session $SESSION_NAME
-
-stop_lttng_sessiond
-
-# Validate test
-
-last_val=0
-out=0
-
-babeltrace $TRACE_PATH | while read event;
-do
-       val=$(echo $event | cut -f10 -d" ")
-       val=${val%?}
-       th=$(echo $event | cut -f13 -d " ")
-
-       if [ $th = '"one"' ]; then
-               ((last_val++))
-               # We expect here a continous value from 1 to 20
-               if [ $last_val -ne $val ]; then
-                       echo -n "[-] One minute event failed ($val) "
-                       out=1
-                       break
-               fi
-       elif [ $th = '"ten"' ]; then
-               # Test 10 minutes counter
-               if [ $val -ne 10 ]; then
-                       # Test 20 minutes counter
-                       if [ $val -ne 20 ]; then
-                               echo -n "[-] Ten minutes event failed ($val) "
-                               out=1
-                               break
-                       fi
-               fi
-       elif [ $th = '"twenty"' ]; then
-               # Test 20 minutes counter
-               if [ $val -ne 20 ]; then
-                       echo -n "[-] Twenty minutes event failed ($val) "
-                       out=1
-                       break
-               fi
-       fi
-done
-
-if [ $out -eq 0 ]; then
-       echo -n "Trace is coherent... "
-       print_ok
-else
-       print_fail
-fi
-
-rm -rf $TRACE_PATH
-
-exit $out
diff --git a/tests/regression/ust/low-throughput/test_low_throughput b/tests/regression/ust/low-throughput/test_low_throughput
new file mode 100755 (executable)
index 0000000..2e11133
--- /dev/null
@@ -0,0 +1,101 @@
+#!/bin/bash
+#
+# Copyright (C) - 2012 David Goulet <dgoulet@efficios.com>
+#
+# This library is free software; you can redistribute it and/or modify it under
+# the terms of the GNU Lesser General Public License as published by the Free
+# Software Foundation; version 2.1 of the License.
+#
+# This library is distributed in the hope that it will be useful, but WITHOUT
+# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
+# FOR A PARTICULAR PURPOSE.  See the GNU Lesser General Public License for more
+# details.
+#
+# You should have received a copy of the GNU Lesser General Public License
+# along with this library; if not, write to the Free Software Foundation, Inc.,
+# 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301 USA
+TEST_DESC="UST tracer - Testing low events throughput"
+
+CURDIR=$(dirname $0)/
+TESTDIR=$CURDIR/../../..
+BIN_NAME="gen-events"
+SESSION_NAME="low-throughput"
+EVENT_NAME="tp:slow"
+
+source $TESTDIR/utils/utils.sh
+
+print_test_banner "$TEST_DESC"
+
+if [ ! -x "$CURDIR/$BIN_NAME" ]; then
+       echo -e "No UST nevents binary detected. Passing."
+       exit 0
+fi
+
+TRACE_PATH=$(mktemp -d)
+
+# MUST set TESTDIR before calling those functions
+
+start_lttng_sessiond
+
+create_lttng_session $SESSION_NAME $TRACE_PATH
+
+enable_ust_lttng_event $SESSION_NAME $EVENT_NAME
+start_lttng_tracing $SESSION_NAME
+
+# This is going to take 20 minutes
+./$CURDIR/$BIN_NAME >/dev/null 2>&1
+
+stop_lttng_tracing $SESSION_NAME
+destroy_lttng_session $SESSION_NAME
+
+stop_lttng_sessiond
+
+# Validate test
+
+last_val=0
+out=0
+
+babeltrace $TRACE_PATH | while read event;
+do
+       val=$(echo $event | cut -f10 -d" ")
+       val=${val%?}
+       th=$(echo $event | cut -f13 -d " ")
+
+       if [ $th = '"one"' ]; then
+               ((last_val++))
+               # We expect here a continous value from 1 to 20
+               if [ $last_val -ne $val ]; then
+                       echo -n "[-] One minute event failed ($val) "
+                       out=1
+                       break
+               fi
+       elif [ $th = '"ten"' ]; then
+               # Test 10 minutes counter
+               if [ $val -ne 10 ]; then
+                       # Test 20 minutes counter
+                       if [ $val -ne 20 ]; then
+                               echo -n "[-] Ten minutes event failed ($val) "
+                               out=1
+                               break
+                       fi
+               fi
+       elif [ $th = '"twenty"' ]; then
+               # Test 20 minutes counter
+               if [ $val -ne 20 ]; then
+                       echo -n "[-] Twenty minutes event failed ($val) "
+                       out=1
+                       break
+               fi
+       fi
+done
+
+if [ $out -eq 0 ]; then
+       echo -n "Trace is coherent... "
+       print_ok
+else
+       print_fail
+fi
+
+rm -rf $TRACE_PATH
+
+exit $out
index d197d72f517de698c0773f57b0a2f0f9bd1bbda1..2d978e593030c82e972265ebaebeabf03756a3bd 100644 (file)
@@ -12,5 +12,5 @@ noinst_PROGRAMS = gen-nevents
 gen_nevents_SOURCES = gen-nevents.c tp.c ust_gen_nevents.h
 gen_nevents_LDADD = -llttng-ust
 
-noinst_SCRIPTS = run
-EXTRA_DIST = run
+noinst_SCRIPTS = test_multi_session
+EXTRA_DIST = test_multi_session
diff --git a/tests/regression/ust/multi-session/run b/tests/regression/ust/multi-session/run
deleted file mode 100755 (executable)
index 18e220d..0000000
+++ /dev/null
@@ -1,91 +0,0 @@
-#!/bin/bash
-#
-# Copyright (C) - 2012 David Goulet <dgoulet@efficios.com>
-#
-# This library is free software; you can redistribute it and/or modify it under
-# the terms of the GNU Lesser General Public License as published by the Free
-# Software Foundation; version 2.1 of the License.
-#
-# This library is distributed in the hope that it will be useful, but WITHOUT
-# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
-# FOR A PARTICULAR PURPOSE.  See the GNU Lesser General Public License for more
-# details.
-#
-# You should have received a copy of the GNU Lesser General Public License
-# along with this library; if not, write to the Free Software Foundation, Inc.,
-# 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301 USA
-TEST_DESC="UST tracer - Multi-session"
-
-CURDIR=$(dirname $0)/
-TESTDIR=$CURDIR/../../..
-NR_ITER=100
-SESSION_NAME="multi-session"
-EVENT_NAME="ust_gen_nevents:tptest"
-
-source $TESTDIR/utils/utils.sh
-
-print_test_banner "$TEST_DESC"
-
-if [ ! -x "$CURDIR/gen-nevents" ]; then
-       echo -e "No UST nevents binary detected. Passing."
-       exit 0
-fi
-
-# MUST set TESTDIR before calling those functions
-
-test_multi_session() {
-       local out
-
-       # BEFORE application is spawned
-       for i in `seq 0 3`; do
-               create_lttng_session "$SESSION_NAME-$i" "$TRACE_PATH/$i"
-               enable_ust_lttng_event "$SESSION_NAME-$i" "$EVENT_NAME$i"
-               start_lttng_tracing "$SESSION_NAME-$i"
-       done
-
-       echo -n "Starting application generating $NR_ITER events... "
-       ./$CURDIR/gen-nevents $NR_ITER &
-       print_ok
-
-       # At least hit one event
-       echo -n "Waiting for events to record "
-       while [ -n "$(pidof gen-nevents)" ]; do
-               echo -n "."
-               sleep 0.1
-       done
-       print_ok
-
-       for i in `seq 0 3`; do
-               stop_lttng_tracing "$SESSION_NAME-$i"
-               destroy_lttng_session "$SESSION_NAME-$i"
-               out=$(babeltrace "$TRACE_PATH/$i" | grep "$EVENT_NAMEi$i" | wc -l)
-               if [ $out -ne $NR_ITER ]; then
-                       echo -n "No event found. Suppose to have at least one... "
-                       print_fail
-                       out=1
-               else
-                       echo -n "Found $out event(s) for $SESSION_NAME-$i. Coherent... "
-                       print_ok
-                       out=0
-               fi
-       done
-
-       return $out
-}
-
-# MUST set TESTDIR before calling those functions
-
-start_lttng_sessiond
-
-TRACE_PATH=$(mktemp -d)
-
-test_multi_session
-out=$?
-if [ $out -ne 0 ]; then
-       stop_lttng_sessiond
-       exit $out
-fi
-
-stop_lttng_sessiond
-
-rm -rf "$TRACE_PATH"
diff --git a/tests/regression/ust/multi-session/test_multi_session b/tests/regression/ust/multi-session/test_multi_session
new file mode 100755 (executable)
index 0000000..18e220d
--- /dev/null
@@ -0,0 +1,91 @@
+#!/bin/bash
+#
+# Copyright (C) - 2012 David Goulet <dgoulet@efficios.com>
+#
+# This library is free software; you can redistribute it and/or modify it under
+# the terms of the GNU Lesser General Public License as published by the Free
+# Software Foundation; version 2.1 of the License.
+#
+# This library is distributed in the hope that it will be useful, but WITHOUT
+# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
+# FOR A PARTICULAR PURPOSE.  See the GNU Lesser General Public License for more
+# details.
+#
+# You should have received a copy of the GNU Lesser General Public License
+# along with this library; if not, write to the Free Software Foundation, Inc.,
+# 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301 USA
+TEST_DESC="UST tracer - Multi-session"
+
+CURDIR=$(dirname $0)/
+TESTDIR=$CURDIR/../../..
+NR_ITER=100
+SESSION_NAME="multi-session"
+EVENT_NAME="ust_gen_nevents:tptest"
+
+source $TESTDIR/utils/utils.sh
+
+print_test_banner "$TEST_DESC"
+
+if [ ! -x "$CURDIR/gen-nevents" ]; then
+       echo -e "No UST nevents binary detected. Passing."
+       exit 0
+fi
+
+# MUST set TESTDIR before calling those functions
+
+test_multi_session() {
+       local out
+
+       # BEFORE application is spawned
+       for i in `seq 0 3`; do
+               create_lttng_session "$SESSION_NAME-$i" "$TRACE_PATH/$i"
+               enable_ust_lttng_event "$SESSION_NAME-$i" "$EVENT_NAME$i"
+               start_lttng_tracing "$SESSION_NAME-$i"
+       done
+
+       echo -n "Starting application generating $NR_ITER events... "
+       ./$CURDIR/gen-nevents $NR_ITER &
+       print_ok
+
+       # At least hit one event
+       echo -n "Waiting for events to record "
+       while [ -n "$(pidof gen-nevents)" ]; do
+               echo -n "."
+               sleep 0.1
+       done
+       print_ok
+
+       for i in `seq 0 3`; do
+               stop_lttng_tracing "$SESSION_NAME-$i"
+               destroy_lttng_session "$SESSION_NAME-$i"
+               out=$(babeltrace "$TRACE_PATH/$i" | grep "$EVENT_NAMEi$i" | wc -l)
+               if [ $out -ne $NR_ITER ]; then
+                       echo -n "No event found. Suppose to have at least one... "
+                       print_fail
+                       out=1
+               else
+                       echo -n "Found $out event(s) for $SESSION_NAME-$i. Coherent... "
+                       print_ok
+                       out=0
+               fi
+       done
+
+       return $out
+}
+
+# MUST set TESTDIR before calling those functions
+
+start_lttng_sessiond
+
+TRACE_PATH=$(mktemp -d)
+
+test_multi_session
+out=$?
+if [ $out -ne 0 ]; then
+       stop_lttng_sessiond
+       exit $out
+fi
+
+stop_lttng_sessiond
+
+rm -rf "$TRACE_PATH"
index b07ae0baafae50f8931e7c1fea7090fc5e3fc283..63a320954c06e1e754c63211526a80dc9842f6c8 100644 (file)
@@ -12,5 +12,5 @@ noinst_PROGRAMS = gen-events-time
 gen_events_time_SOURCES = gen-events-time.c tp.c ust_gen_event.h
 gen_events_time_LDADD = -llttng-ust
 
-noinst_SCRIPTS = run ust-nprocesses
-EXTRA_DIST = run ust-nprocesses
+noinst_SCRIPTS = test_nprocesses ust-nprocesses
+EXTRA_DIST = test_nprocesses ust-nprocesses
diff --git a/tests/regression/ust/nprocesses/run b/tests/regression/ust/nprocesses/run
deleted file mode 100755 (executable)
index 55ad148..0000000
+++ /dev/null
@@ -1,41 +0,0 @@
-#!/bin/bash
-#
-# Copyright (C) - 2012 David Goulet <dgoulet@efficios.com>
-#
-# This library is free software; you can redistribute it and/or modify it under
-# the terms of the GNU Lesser General Public License as published by the Free
-# Software Foundation; version 2.1 of the License.
-#
-# This library is distributed in the hope that it will be useful, but WITHOUT
-# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
-# FOR A PARTICULAR PURPOSE.  See the GNU Lesser General Public License for more
-# details.
-#
-# You should have received a copy of the GNU Lesser General Public License
-# along with this library; if not, write to the Free Software Foundation, Inc.,
-# 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301 USA
-NR_ITER=100
-TEST_DESC="UST tracer - Generate $NR_ITER process"
-
-CURDIR=$(dirname $0)/
-TESTDIR=$CURDIR/../../..
-TEST_BIN_NAME="gen-events-time"
-
-source $TESTDIR/utils/utils.sh
-
-print_test_banner "$TEST_DESC"
-
-if [ ! -x "$CURDIR/$TEST_BIN_NAME" ]; then
-       echo -e "No UST $TEST_BIN_NAME binary detected. Passing."
-       exit 0
-fi
-
-# MUST set TESTDIR before calling those functions
-
-start_lttng_sessiond
-
-./$CURDIR/ust-nprocesses $NR_ITER
-
-stop_lttng_sessiond
-
-exit 0
diff --git a/tests/regression/ust/nprocesses/test_nprocesses b/tests/regression/ust/nprocesses/test_nprocesses
new file mode 100755 (executable)
index 0000000..55ad148
--- /dev/null
@@ -0,0 +1,41 @@
+#!/bin/bash
+#
+# Copyright (C) - 2012 David Goulet <dgoulet@efficios.com>
+#
+# This library is free software; you can redistribute it and/or modify it under
+# the terms of the GNU Lesser General Public License as published by the Free
+# Software Foundation; version 2.1 of the License.
+#
+# This library is distributed in the hope that it will be useful, but WITHOUT
+# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
+# FOR A PARTICULAR PURPOSE.  See the GNU Lesser General Public License for more
+# details.
+#
+# You should have received a copy of the GNU Lesser General Public License
+# along with this library; if not, write to the Free Software Foundation, Inc.,
+# 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301 USA
+NR_ITER=100
+TEST_DESC="UST tracer - Generate $NR_ITER process"
+
+CURDIR=$(dirname $0)/
+TESTDIR=$CURDIR/../../..
+TEST_BIN_NAME="gen-events-time"
+
+source $TESTDIR/utils/utils.sh
+
+print_test_banner "$TEST_DESC"
+
+if [ ! -x "$CURDIR/$TEST_BIN_NAME" ]; then
+       echo -e "No UST $TEST_BIN_NAME binary detected. Passing."
+       exit 0
+fi
+
+# MUST set TESTDIR before calling those functions
+
+start_lttng_sessiond
+
+./$CURDIR/ust-nprocesses $NR_ITER
+
+stop_lttng_sessiond
+
+exit 0
index 7100034f99c14510263569846b22bedcfe9dc84f..d90146f9f63f0a3d83ea504589f3747420c0b529 100644 (file)
@@ -1,4 +1,4 @@
 SUBDIRS = demo
 
-noinst_SCRIPTS = run
-EXTRA_DIST = run overlap.sh
+noinst_SCRIPTS = test_overlap
+EXTRA_DIST = test_overlap overlap.sh
diff --git a/tests/regression/ust/overlap/run b/tests/regression/ust/overlap/run
deleted file mode 100755 (executable)
index ca8efb3..0000000
+++ /dev/null
@@ -1,24 +0,0 @@
-#!/bin/bash
-
-DIR=$(dirname $0)
-
-tests=( $DIR/overlap.sh)
-
-exit_code=0
-
-function start_tests ()
-{
-    for bin in ${tests[@]};
-    do
-        ./$bin
-        # Test must return 0 to pass.
-        if [ $? -ne 0 ]; then
-            exit_code=1
-            break
-        fi
-    done
-}
-
-start_tests
-
-exit $exit_code
diff --git a/tests/regression/ust/overlap/test_overlap b/tests/regression/ust/overlap/test_overlap
new file mode 100755 (executable)
index 0000000..ca8efb3
--- /dev/null
@@ -0,0 +1,24 @@
+#!/bin/bash
+
+DIR=$(dirname $0)
+
+tests=( $DIR/overlap.sh)
+
+exit_code=0
+
+function start_tests ()
+{
+    for bin in ${tests[@]};
+    do
+        ./$bin
+        # Test must return 0 to pass.
+        if [ $? -ne 0 ]; then
+            exit_code=1
+            break
+        fi
+    done
+}
+
+start_tests
+
+exit $exit_code
index 01afceca7c4f94394ef28a3e43f73e1734d13b26..89aa3bb3bc650153eff6a914476bc61416b57264 100755 (executable)
@@ -2,9 +2,9 @@
 
 DIR=$(dirname $0)
 
-tests=( $DIR/run-ust-global-tests.sh $DIR/nprocesses/run \
-               $DIR/high-throughput/run $DIR/before-after/run \
-               $DIR/multi-session/run $DIR/overlap/run )
+tests=( $DIR/run-ust-global-tests.sh $DIR/nprocesses/test_nprocesses \
+               $DIR/high-throughput/test_high_throughput $DIR/before-after/test_before_after \
+               $DIR/multi-session/test_multi_session $DIR/overlap/test_overlap )
 
 # $DIR/low-throughput/run --> DEACTIVATED.
 # Use only for release. This test last 20 minutes
This page took 0.042469 seconds and 5 git commands to generate.