summaryrefslogtreecommitdiff
path: root/apps
diff options
context:
space:
mode:
authorCorey Farrell <git@cfware.com>2016-07-18 19:39:39 -0400
committerCorey Farrell <git@cfware.com>2016-07-18 19:39:39 -0400
commitc8e41d14a1478b46a6c986a4c30ba2c8bdf86cd5 (patch)
tree1a40f381d57d0155665fc63aad6855507337836c /apps
parent962c7ef5d91c546794313e01b4c264efdf3d1ead (diff)
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
Diffstat (limited to 'apps')
-rw-r--r--apps/app_voicemail.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/apps/app_voicemail.c b/apps/app_voicemail.c
index e88d7069c..321e5c9c0 100644
--- a/apps/app_voicemail.c
+++ b/apps/app_voicemail.c
@@ -12228,6 +12228,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;
@@ -12415,6 +12416,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)
{