From c8e41d14a1478b46a6c986a4c30ba2c8bdf86cd5 Mon Sep 17 00:00:00 2001 From: Corey Farrell Date: Mon, 18 Jul 2016 19:39:39 -0400 Subject: Unit tests: Use AST_TEST_DEFINE in conditional code only. If AST_TEST_DEFINE is not conditional to TEST_FRAMEWORK it produces dead code. This places all existing unit tests into a conditional block if they weren't already. ASTERISK-26211 #close Change-Id: I8ef83ee11cbc991b07b7a37ecb41433e8c734686 --- res/res_pjsip.c | 2 ++ 1 file changed, 2 insertions(+) (limited to 'res/res_pjsip.c') diff --git a/res/res_pjsip.c b/res/res_pjsip.c index de8eb3e8a..40916684a 100644 --- a/res/res_pjsip.c +++ b/res/res_pjsip.c @@ -4118,6 +4118,7 @@ long ast_sip_threadpool_queue_size(void) return ast_threadpool_queue_size(sip_threadpool); } +#ifdef TEST_FRAMEWORK AST_TEST_DEFINE(xml_sanitization_end_null) { char sanitized[8]; @@ -4168,6 +4169,7 @@ AST_TEST_DEFINE(xml_sanitization_exceeds_buffer) return AST_TEST_PASS; } +#endif /*! * \internal -- cgit v1.2.3