mirror of
https://github.com/isc-projects/bind9.git
synced 2026-05-28 04:34:54 -04:00
[9.18] fix: test: ISC_RUN_TEST_IMPL should use a static declaration
These functions don't need to be called from multiple places and by making them static we will detect when they are not added to the list functions to be tested. Closes #5715 Backport of MR !11480 Merge branch 'backport-5715-isc_run_test_impl-should-use-a-static-declaration-9.18' into 'bind-9.18' See merge request isc-projects/bind9!11503
This commit is contained in:
commit
804dababd0
2 changed files with 5 additions and 4 deletions
|
|
@ -90,7 +90,7 @@ teardown_managers(void **state);
|
|||
int setup_test_##name(void **state __attribute__((unused)));
|
||||
|
||||
#define ISC_RUN_TEST_DECLARE(name) \
|
||||
void run_test_##name(void **state __attribute__((unused)));
|
||||
static void run_test_##name(void **state __attribute__((unused)));
|
||||
|
||||
#define ISC_TEARDOWN_TEST_DECLARE(name) \
|
||||
int teardown_test_##name(void **state __attribute__((unused)))
|
||||
|
|
@ -99,9 +99,9 @@ teardown_managers(void **state);
|
|||
int setup_test_##name(void **state __attribute__((unused))); \
|
||||
int setup_test_##name(void **state __attribute__((unused)))
|
||||
|
||||
#define ISC_RUN_TEST_IMPL(name) \
|
||||
void run_test_##name(void **state __attribute__((unused))); \
|
||||
void run_test_##name(void **state __attribute__((unused)))
|
||||
#define ISC_RUN_TEST_IMPL(name) \
|
||||
static void run_test_##name(void **state __attribute__((unused))); \
|
||||
static void run_test_##name(void **state __attribute__((unused)))
|
||||
|
||||
#define ISC_TEARDOWN_TEST_IMPL(name) \
|
||||
int teardown_test_##name(void **state __attribute__((unused))); \
|
||||
|
|
|
|||
|
|
@ -1463,6 +1463,7 @@ ISC_TEST_ENTRY_CUSTOM(privilege_drop, _setup, _teardown)
|
|||
ISC_TEST_ENTRY_CUSTOM(privileged_events, _setup, _teardown)
|
||||
ISC_TEST_ENTRY_CUSTOM(purge, _setup2, _teardown)
|
||||
ISC_TEST_ENTRY_CUSTOM(purgeevent, _setup2, _teardown)
|
||||
ISC_TEST_ENTRY_CUSTOM(purgerange, _setup2, _teardown)
|
||||
ISC_TEST_ENTRY_CUSTOM(task_shutdown, _setup4, _teardown)
|
||||
ISC_TEST_ENTRY_CUSTOM(task_exclusive, _setup4, _teardown)
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue