From dc807017742411a9a0e328bb25a592aaf10df11e Mon Sep 17 00:00:00 2001 From: Simon Marchi Date: Fri, 9 Aug 2019 17:17:35 -0400 Subject: [PATCH] tests: make auto-source-discovery-{log_level,params} tests use sink.text.details For the same rationale as the previous patch, change how the test component classes for test_auto_source_discovery_params and test_auto_source_discovery_log_level report what they receive from a print to stdout to stream name. Change-Id: I62405ccd1fbdbe708fbec5dacc52894d4060dfb0 Signed-off-by: Simon Marchi Reviewed-on: https://review.lttng.org/c/babeltrace/+/1864 Reviewed-by: Philippe Proulx Tested-by: jenkins --- .../test_auto_source_discovery_log_level | 104 ++++++++++++++---- .../convert/test_auto_source_discovery_params | 100 ++++++++++++++--- .../bt_plugin_test.py | 70 +++++++----- 3 files changed, 210 insertions(+), 64 deletions(-) diff --git a/tests/cli/convert/test_auto_source_discovery_log_level b/tests/cli/convert/test_auto_source_discovery_log_level index 6d2430e4..5e79b013 100755 --- a/tests/cli/convert/test_auto_source_discovery_log_level +++ b/tests/cli/convert/test_auto_source_discovery_log_level @@ -15,8 +15,8 @@ # this program; if not, write to the Free Software Foundation, Inc., 51 # Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. -# Test log level options are applied to sources auto-discovered by the convert -# command. +# Test how log level options are applied to sources auto-discovered by the +# convert command. if [ "x${BT_TESTS_SRCDIR:-}" != "x" ]; then UTILSSH="$BT_TESTS_SRCDIR/utils/utils.sh" @@ -38,55 +38,119 @@ dir_b="${data_dir}/dir-b" dir_ab="${data_dir}/dir-ab" expected_file=$(mktemp -t expected.XXXXXX) -stderr_expected=/dev/null -print_log_level="--params print=\"log-level\"" +print_log_level="--params what=\"log-level\"" +details_sink=("-c" "sink.text.details" "--params=with-metadata=false") debug=2 trace=1 # Apply log level to two components from one non-option argument. cat > "$expected_file" < "$expected_file" < "$expected_file" < "$expected_file" < "$expected_file" < "$expected_file" < "$expected_file" < "$expected_file" <