From 84367f8424db3d97c7b0170360584b4d40ff2f5e Mon Sep 17 00:00:00 2001 From: Robin Mueller Date: Tue, 1 Mar 2022 14:51:12 +0100 Subject: [PATCH] small tweak --- bsp_q7s/core/CoreController.h | 2 +- unittest/rebootLogic/src/CoreController.h | 2 +- unittest/rebootLogic/src/main.cpp | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/bsp_q7s/core/CoreController.h b/bsp_q7s/core/CoreController.h index 37f5395d..48bc9b7f 100644 --- a/bsp_q7s/core/CoreController.h +++ b/bsp_q7s/core/CoreController.h @@ -23,7 +23,7 @@ enum Copy : int { COPY_0, COPY_1, NO_COPY, SELF_COPY, ALL_COPY }; struct RebootFile { static constexpr uint8_t DEFAULT_MAX_BOOT_CNT = 10; - bool enabled = false; + bool enabled = true; size_t maxCount = DEFAULT_MAX_BOOT_CNT; uint32_t img00Cnt = 0; uint32_t img01Cnt = 0; diff --git a/unittest/rebootLogic/src/CoreController.h b/unittest/rebootLogic/src/CoreController.h index 737d550d..eec0d959 100644 --- a/unittest/rebootLogic/src/CoreController.h +++ b/unittest/rebootLogic/src/CoreController.h @@ -18,7 +18,7 @@ enum Copy : int { COPY_0, COPY_1, NO_COPY, SELF_COPY, ALL_COPY }; struct RebootFile { static constexpr uint8_t DEFAULT_MAX_BOOT_CNT = 10; - bool enabled = false; + bool enabled = true; size_t maxCount = DEFAULT_MAX_BOOT_CNT; uint32_t img00Cnt = 0; uint32_t img01Cnt = 0; diff --git a/unittest/rebootLogic/src/main.cpp b/unittest/rebootLogic/src/main.cpp index b24b4014..14ae8be8 100644 --- a/unittest/rebootLogic/src/main.cpp +++ b/unittest/rebootLogic/src/main.cpp @@ -32,7 +32,7 @@ TEST_CASE( "Core Controller Reboot File Handling", "[reboot-file]" ) { xsc_libnor_copy_t copy; RebootFile rf = {}; ctrl.rewriteRebootFile(rf); - REQUIRE(rf.enabled == 0); + REQUIRE(rf.enabled == 1); REQUIRE(rf.maxCount == RebootFile::DEFAULT_MAX_BOOT_CNT); REQUIRE(rf.img00Cnt == 0); REQUIRE(rf.img01Cnt == 0);