From e5c06254ccbdab5762325889801f329a7e9bb26a Mon Sep 17 00:00:00 2001 From: Gautier Pelloux-Prayer Date: Thu, 9 Jun 2016 15:03:03 +0200 Subject: [PATCH] TestsLiblinphone: turn off logs totally when runnig automated tests on real device, so that xcodebuild has a chance to parse results correctly --- TestsLiblinphone/LinphoneTester_Tests.m | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/TestsLiblinphone/LinphoneTester_Tests.m b/TestsLiblinphone/LinphoneTester_Tests.m index 74a075b79..8a4877065 100644 --- a/TestsLiblinphone/LinphoneTester_Tests.m +++ b/TestsLiblinphone/LinphoneTester_Tests.m @@ -35,9 +35,13 @@ void tester_logs_handler(int level, const char *fmt, va_list args) { } + (void)initialize { - // turn off logs since jenkins fails to parse output otherwise. If - // you want to debug a specific test, comment this temporary - [Log enableLogs:ORTP_WARNING]; +#if TARGET_IPHONE_SIMULATOR + [Log enableLogs:ORTP_DEBUG]; +#else + // turn off logs since xcodebuild fails to retrieve whole output otherwise on + // real device. If you need to debug, comment this line temporary + [Log enableLogs:NO]; +#endif bc_tester_init(tester_logs_handler, ORTP_MESSAGE, ORTP_ERROR, "rcfiles"); liblinphone_tester_add_suites();