renames some things in config tests

master
Jonathan Hodgson 2 years ago
parent 18d50ed7a6
commit 0e53f180ad
  1. 8
      tests/all.test.c
  2. 9
      tests/config.test.c

@ -2,8 +2,14 @@
#define MAINTEST
#include "munit/munit.h"
#include "config.test.c"
#include "request.test.c"
#include "response.test.c"
#ifndef REQUESTRESPONSE_C
#define REQUESTRESPONSE_C value
#include "requestresponse.test.c"
#endif /* ifndef REQUESTRESPONSE_C */
#include <string.h>
#include <stdio.h>
@ -15,6 +21,8 @@ int main (int argc, char* argv[]) {
MunitSuite all_suites[] = {
config_test_suite,
request_test_suite,
response_test_suite,
requestresponse_test_suite,
{ NULL, NULL, NULL, 0, MUNIT_SUITE_OPTION_NONE }
};

@ -1,3 +1,6 @@
#ifndef CONFIG_TEST
#define CONFIG_TEST
#include "munit/munit.h"
#include "../src/config.c"
#include <unistd.h> //This has getcwd
@ -80,7 +83,7 @@ MunitResult checkSetConfig(const MunitParameter params[],
return MUNIT_OK;
}
MunitTest tests[] = {
static MunitTest config_tests[] = {
{
"/path_exists/yes", /* name */
pathThatExists, /* test */
@ -144,7 +147,7 @@ MunitTest tests[] = {
MunitSuite config_test_suite = {
"/config", /* name */
tests, /* tests */
config_tests, /* tests */
NULL, /* suites */
1, /* iterations */
MUNIT_SUITE_OPTION_NONE /* options */
@ -158,3 +161,5 @@ int main (int argc, char* argv[]) {
}
#endif /* ifndef MAINTEST */
#endif /* ifndef CONFIG_TEST */

Loading…
Cancel
Save