fix up tests

This commit is contained in:
Brett Christensen 2024-02-09 15:36:35 +11:00
parent 3a47b3eb42
commit ef7225624b
5 changed files with 16 additions and 9 deletions

View file

@ -3,8 +3,8 @@
#include "../../../USER_SETTINGS.h" #include "../../../USER_SETTINGS.h"
#include "../config.h" #include "../config.h"
static unsigned long previous_millis = 0; unsigned long previous_millis = 0;
static uint32_t time_seconds = 0; uint32_t time_seconds = 0;
static uint8_t total_led_color = GREEN; static uint8_t total_led_color = GREEN;
static char event_message[256]; static char event_message[256];
EVENTS_STRUCT_TYPE entries[EVENT_NOF_EVENTS]; EVENTS_STRUCT_TYPE entries[EVENT_NOF_EVENTS];

View file

@ -3,6 +3,8 @@
#ifndef UNIT_TEST #ifndef UNIT_TEST
#include <Arduino.h> #include <Arduino.h>
extern unsigned long time_seconds;
extern uint32_t previous_millis;
#endif #endif
#include <stdint.h> #include <stdint.h>

View file

@ -65,8 +65,8 @@ extern uint16_t OBC_Charge_Power;
*/ */
void init_webserver(); void init_webserver();
/* /**
* @brief loop for monitoring wifi. * @brief Monitoring loop for WiFi. Will attempt to reconnect to access point if the connection goes down.
* *
* @param[in] void * @param[in] void
* *

View file

@ -1,9 +1,14 @@
// The test library must be included first! // The test library must be included first!
#include "test_lib.h" #include "../test_lib.h"
#include "events.cpp" #include "../../Software/src/devboard/utils/events.h"
#define EVENTLOGGING
#define DUMMY_EVENT_ENABLED true
/* Helper functions */ /* Helper functions */
static char event_message[256]; // Declare the event_message variable
static void reset_event_msg(void) { static void reset_event_msg(void) {
snprintf(event_message, sizeof(event_message), ""); snprintf(event_message, sizeof(event_message), "");
} }

View file

@ -1,7 +1,7 @@
// The test library must be included first! // The test library must be included first!
#include "../test_lib.h" #include "../test_lib.h"
#include "timer.cpp" #include "../../Software/src/devboard/utils/timer.cpp"
/* Helper functions */ /* Helper functions */