projects
/
lttng-tools.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Tests: remove declaration already present in utils.sh
[lttng-tools.git]
/
tests
/
regression
/
tools
/
filtering
/
test_valid_filter
diff --git
a/tests/regression/tools/filtering/test_valid_filter
b/tests/regression/tools/filtering/test_valid_filter
index 28347a42cc52395dd10329d4c5fb3c807ec20dac..328e2f71a256315cd03de5e904a83c99405a5019 100755
(executable)
--- a/
tests/regression/tools/filtering/test_valid_filter
+++ b/
tests/regression/tools/filtering/test_valid_filter
@@
-19,13
+19,12
@@
TEST_DESC="Filtering - Valid filters"
CURDIR=$(dirname $0)/
TESTDIR=$CURDIR/../../..
CURDIR=$(dirname $0)/
TESTDIR=$CURDIR/../../..
-LTTNG_BIN="lttng"
STATS_BIN="$TESTDIR/utils/babelstats.pl"
SESSION_NAME="valid_filter"
NR_ITER=100
NUM_GLOBAL_TESTS=2
STATS_BIN="$TESTDIR/utils/babelstats.pl"
SESSION_NAME="valid_filter"
NR_ITER=100
NUM_GLOBAL_TESTS=2
-NUM_UST_TESTS=
288
-NUM_KERNEL_TESTS=
288
+NUM_UST_TESTS=
330
+NUM_KERNEL_TESTS=
330
NUM_TESTS=$(($NUM_UST_TESTS+$NUM_KERNEL_TESTS+$NUM_GLOBAL_TESTS))
source $TESTDIR/utils/utils.sh
NUM_TESTS=$(($NUM_UST_TESTS+$NUM_KERNEL_TESTS+$NUM_GLOBAL_TESTS))
source $TESTDIR/utils/utils.sh
@@
-72,7
+71,7
@@
function test_valid_filter
create_lttng_session_ok $SESSION_NAME $trace_path
# Enable filter
create_lttng_session_ok $SESSION_NAME $trace_path
# Enable filter
- enable_lttng_event_filter $domain $SESSION_NAME
$event_name $filter
+ enable_lttng_event_filter $domain $SESSION_NAME
"$event_name" "$filter"
# Trace apps
start_lttng_tracing_ok $SESSION_NAME
# Trace apps
start_lttng_tracing_ok $SESSION_NAME
@@
-344,8
+343,6
@@
plan_tests $NUM_TESTS
print_test_banner "$TEST_DESC"
print_test_banner "$TEST_DESC"
-IFS=$'\n'
-
issue_356_filter="intfield > 0 && intfield > 1 && "
issue_356_filter+="intfield > 2 && intfield > 3 && "
issue_356_filter+="intfield > 4 && intfield > 5 && "
issue_356_filter="intfield > 0 && intfield > 1 && "
issue_356_filter+="intfield > 2 && intfield > 3 && "
issue_356_filter+="intfield > 4 && intfield > 5 && "
@@
-360,6
+357,9
@@
BIN_NAME="gen-ust-events"
# One to one mapping between filters and validators
# One to one mapping between filters and validators
+# Set IFS to newline to facilitate array declaration
+OLDIFS="$IFS"
+IFS=$'\n'
UST_FILTERS=("intfield" #1
"intfield > 1" #2
"intfield >= 1" #3
UST_FILTERS=("intfield" #1
"intfield > 1" #2
"intfield >= 1" #3
@@
-408,6
+408,13
@@
UST_FILTERS=("intfield" #1
"\$ctx.procname == \"*\"" #46
"\"*\" != \$ctx.procname" #47
"\"*\" == \$ctx.procname" #48
"\$ctx.procname == \"*\"" #46
"\"*\" != \$ctx.procname" #47
"\"*\" == \$ctx.procname" #48
+ "!a.f.d" #49
+ "a.a.a.a.a.a.a.a.a.a.a.a.a.a.a.a.a.a.a.a" #50
+ "\$ctx.vtid.blah == 0" #51
+ "asdf.asdfsd.sadf < 4" #52
+ "0 == \$ctx.vtid.blah" #53
+ "\$ctx.44 == 0" #54
+ "0 == \$ctx.44" #55
)
UST_FILTER_COUNT=${#UST_FILTERS[@]}
)
UST_FILTER_COUNT=${#UST_FILTERS[@]}
@@
-464,8
+471,17
@@
UST_VALIDATOR=("validator_intfield" #1
"validator_has_events" #46
"validator_has_no_event" #47
"validator_has_events" #48
"validator_has_events" #46
"validator_has_no_event" #47
"validator_has_events" #48
+ "validator_has_no_event" #49
+ "validator_has_no_event" #50
+ "validator_has_no_event" #51
+ "validator_has_no_event" #52
+ "validator_has_no_event" #53
+ "validator_has_no_event" #54
+ "validator_has_no_event" #55
)
)
+IFS="$OLDIFS"
+
diag "Test UST valid filters"
KERNEL_CHECK=0
diag "Test UST valid filters"
KERNEL_CHECK=0
@@
-488,7
+504,9
@@
done
BIN_NAME="test_valid_filt" # Current script name truncated by kernel
# One to one mapping between filters and validators
BIN_NAME="test_valid_filt" # Current script name truncated by kernel
# One to one mapping between filters and validators
-
+# Set IFS to newline to facilitate array declaration
+OLDIFS="$IFS"
+IFS=$'\n'
KERNEL_FILTERS=("intfield" #1
"intfield > 1" #2
"intfield >= 1" #3
KERNEL_FILTERS=("intfield" #1
"intfield > 1" #2
"intfield >= 1" #3
@@
-537,6
+555,13
@@
KERNEL_FILTERS=("intfield" #1
"\$ctx.procname == \"*\"" #46
"\"*\" != \$ctx.procname" #47
"\"*\" == \$ctx.procname" #48
"\$ctx.procname == \"*\"" #46
"\"*\" != \$ctx.procname" #47
"\"*\" == \$ctx.procname" #48
+ "!a.f.d" #49
+ "a.a.a.a.a.a.a.a.a.a.a.a.a.a.a.a.a.a.a.a" #50
+ "\$ctx.vtid.blah == 0" #51
+ "asdf.asdfsd.sadf < 4" #52
+ "0 == \$ctx.vtid.blah" #53
+ "\$ctx.44 == 0" #54
+ "0 == \$ctx.44" #55
)
KERNEL_FILTER_COUNT=${#KERNEL_FILTERS[@]}
)
KERNEL_FILTER_COUNT=${#KERNEL_FILTERS[@]}
@@
-589,8
+614,17
@@
KERNEL_VALIDATOR=("validator_intfield" #1
"validator_has_events" #46
"validator_has_no_event" #47
"validator_has_events" #48
"validator_has_events" #46
"validator_has_no_event" #47
"validator_has_events" #48
+ "validator_has_no_event" #49
+ "validator_has_no_event" #50
+ "validator_has_no_event" #51
+ "validator_has_no_event" #52
+ "validator_has_no_event" #53
+ "validator_has_no_event" #54
+ "validator_has_no_event" #55
)
)
+IFS=$OLDIFS
+
if [ "$(id -u)" == "0" ]; then
isroot=1
else
if [ "$(id -u)" == "0" ]; then
isroot=1
else
This page took
0.026654 seconds
and
4
git commands to generate.