add console tests to Unity

This commit is contained in:
proddy
2024-08-06 10:33:22 +02:00
parent 3045144cc3
commit 7b6fe53e74
7 changed files with 118 additions and 28 deletions

View File

@@ -1397,8 +1397,13 @@ bool System::command_info(const char * value, const int8_t id, JsonObject output
JsonObject node;
// System
node = output["system"].to<JsonObject>();
node["version"] = EMSESP_APP_VERSION;
node = output["system"].to<JsonObject>();
// prevent false negataive in Unity tests everytime the version changes
#if defined(EMSESP_UNITY)
node["version"] = "dev";
#else
node["version"] = EMSESP_APP_VERSION;
#endif
node["uptime"] = uuid::log::format_timestamp_ms(uuid::get_uptime_ms(), 3);
node["uptimeSec"] = uuid::get_uptime_sec();
#ifndef EMSESP_STANDALONE