From cf1188a1be7c81892f480474eedf1a5639a1c1eb Mon Sep 17 00:00:00 2001 From: Corey Farrell Date: Mon, 18 Jul 2016 19:40:22 -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 --- apps/app_voicemail.c | 2 ++ 1 file changed, 2 insertions(+) (limited to 'apps/app_voicemail.c') diff --git a/apps/app_voicemail.c b/apps/app_voicemail.c index 6607f529e..894038bdb 100644 --- a/apps/app_voicemail.c +++ b/apps/app_voicemail.c @@ -12307,6 +12307,7 @@ static int append_mailbox(const char *context, const char *box, const char *data return 0; } +#ifdef TEST_FRAMEWORK AST_TEST_DEFINE(test_voicemail_vmuser) { int res = 0; @@ -12494,6 +12495,7 @@ AST_TEST_DEFINE(test_voicemail_vmuser) free_user(vmu); return res ? AST_TEST_FAIL : AST_TEST_PASS; } +#endif static int vm_box_exists(struct ast_channel *chan, const char *data) { -- cgit v1.2.3