Wed Jan 8 2020 09:50:21

Asterisk developer's documentation


test.h File Reference

Test Framework API. More...

Go to the source code of this file.

Data Structures

struct  ast_test_info
 Contains all the initialization information required to store a new test definition. More...
 

Macros

#define AST_TEST_DEFINE(hdr)   static enum ast_test_result_state attribute_unused hdr(struct ast_test_info *info, enum ast_test_command cmd, struct ast_test *test)
 
#define AST_TEST_REGISTER(cb)
 
#define ast_test_status_update(a, b, c...)
 
#define ast_test_suite_assert(exp)   (void)0;
 
#define ast_test_suite_event_notify(s, f,...)   (void)0;
 
#define AST_TEST_UNREGISTER(cb)
 

Enumerations

enum  ast_test_command { TEST_INIT, TEST_EXECUTE }
 
enum  ast_test_result_state { AST_TEST_NOT_RUN, AST_TEST_PASS, AST_TEST_FAIL }
 

Detailed Description

Test Framework API.

For an overview on how to use the test API, see Asterisk Unit Test API

Author
David Vossel dvoss.nosp@m.el@d.nosp@m.igium.nosp@m..com
Russell Bryant russe.nosp@m.ll@d.nosp@m.igium.nosp@m..com

Definition in file test.h.

Macro Definition Documentation

#define AST_TEST_DEFINE (   hdr)    static enum ast_test_result_state attribute_unused hdr(struct ast_test_info *info, enum ast_test_command cmd, struct ast_test *test)

Macros used for defining and registering a test

Definition at line 126 of file test.h.

#define ast_test_status_update (   a,
  b,
  c... 
)

Definition at line 129 of file test.h.

Referenced by AST_TEST_DEFINE(), and build_conf().

#define ast_test_suite_assert (   exp)    (void)0;

Definition at line 185 of file test.h.

Referenced by vm_execmain().

Enumeration Type Documentation

Enumerator
TEST_INIT 
TEST_EXECUTE 

Definition at line 195 of file test.h.

195  {
196  TEST_INIT,
197  TEST_EXECUTE,
198 };
Enumerator
AST_TEST_NOT_RUN 
AST_TEST_PASS 
AST_TEST_FAIL 

Definition at line 189 of file test.h.

189  {
193 };