mirror of
https://github.com/tbamud/tbamud.git
synced 2026-01-30 04:45:17 +01:00
Testing do_remove
Mocking the send_to_char function to check messages to the user. Still doesn't work for act() though. Requires libmocka-dev and libunwind-setjmp0-dev
This commit is contained in:
parent
217eac8cb3
commit
7d3acb0e3d
4 changed files with 83 additions and 5 deletions
|
|
@ -18,6 +18,10 @@
|
|||
#include "../quest.h"
|
||||
#include "../mud_event.h"
|
||||
#include "../munit/munit.h"
|
||||
#include <stdarg.h>
|
||||
#include <stddef.h>
|
||||
#include <setjmp.h>
|
||||
#include <cmocka.h>
|
||||
|
||||
/**
|
||||
* Utility macro for defining tests.
|
||||
|
|
@ -30,4 +34,10 @@
|
|||
*/
|
||||
#define STD_TEST(test_name, test_fun) { (char *)(test_name), (test_fun), NULL, NULL, MUNIT_TEST_OPTION_NONE, NULL }
|
||||
|
||||
/*
|
||||
* test fixtures
|
||||
*/
|
||||
char_data* create_test_char_data();
|
||||
char *get_last_messages();
|
||||
|
||||
#endif
|
||||
Loading…
Add table
Add a link
Reference in a new issue