[PATCH] osmo-mgw[master]: client: fix stderror logging in unit-test

dexter gerrit-no-reply at lists.osmocom.org
Wed Oct 25 10:24:39 UTC 2017

Review at  https://gerrit.osmocom.org/4412

client: fix stderror logging in unit-test

When testing the file name and the line numbers are output to
stderr, this causes the test to fail when change moves the

Disable line numbers in the stderror log when testing, also
disable timestamps and colors. Make sure the log category
is print.

Change-Id: I7f1bd9454188f0ca869dada1fcc2877b789cc0ac
M tests/mgcp_client/mgcp_client_test.c
1 file changed, 4 insertions(+), 0 deletions(-)

  git pull ssh://gerrit.osmocom.org:29418/osmo-mgw refs/changes/12/4412/1

diff --git a/tests/mgcp_client/mgcp_client_test.c b/tests/mgcp_client/mgcp_client_test.c
index f2f0e0f..69e1810 100644
--- a/tests/mgcp_client/mgcp_client_test.c
+++ b/tests/mgcp_client/mgcp_client_test.c
@@ -163,6 +163,10 @@
 	ctx = talloc_named_const(NULL, 1, "mgcp_client_test");
 	msgb_talloc_ctx_init(ctx, 0);
+	log_set_print_filename(osmo_stderr_target, 0);
+	log_set_print_timestamp(osmo_stderr_target, 0);
+	log_set_use_color(osmo_stderr_target, 0);
+	log_set_print_category(osmo_stderr_target, 1);

To view, visit https://gerrit.osmocom.org/4412
To unsubscribe, visit https://gerrit.osmocom.org/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: I7f1bd9454188f0ca869dada1fcc2877b789cc0ac
Gerrit-PatchSet: 1
Gerrit-Project: osmo-mgw
Gerrit-Branch: master
Gerrit-Owner: dexter <pmaier at sysmocom.de>

More information about the gerrit-log mailing list