From ebeb8f371f32b6e4ba1b673d7a3c7a8b9c1ea761 Mon Sep 17 00:00:00 2001 From: Anh D Van Date: Tue, 10 Sep 2024 14:26:38 +0000 Subject: [PATCH 1/3] Fix #2597, fix sb coverage test failure Fix #2597, fix sb coverage test failure involving topic ID --- modules/sb/ut-coverage/sb_UT.c | 96 +++++++++++++++++++++++++++++----- 1 file changed, 82 insertions(+), 14 deletions(-) diff --git a/modules/sb/ut-coverage/sb_UT.c b/modules/sb/ut-coverage/sb_UT.c index 770b6963b..8988eb77e 100644 --- a/modules/sb/ut-coverage/sb_UT.c +++ b/modules/sb/ut-coverage/sb_UT.c @@ -4629,56 +4629,124 @@ void Test_CFE_SB_ValidateMsgId(void) void Test_CFE_SB_CmdTopicIdToMsgId(void) { - CFE_SB_MsgId_Atom_t MsgIdVal; + CFE_SB_MsgId_Atom_t MsgIdVal1; + CFE_SB_MsgId_Atom_t MsgIdVal2; + bool ReturnCode1 = false; + bool ReturnCode2 = false; + + MsgIdVal1 = CFE_SB_CmdTopicIdToMsgId(1, 1); + ReturnCode1 = CFE_SB_IsValidMsgId(CFE_SB_ValueToMsgId(MsgIdVal1)); - MsgIdVal = CFE_SB_CmdTopicIdToMsgId(1, 1); - UtAssert_BOOL_TRUE(CFE_SB_IsValidMsgId(CFE_SB_ValueToMsgId(MsgIdVal))); + MsgIdVal2 = CFE_SB_CmdTopicIdToMsgId(1, 0); + ReturnCode2 = CFE_SB_IsValidMsgId(CFE_SB_ValueToMsgId(MsgIdVal2)); - MsgIdVal = CFE_SB_CmdTopicIdToMsgId(1, 0); - UtAssert_BOOL_TRUE(CFE_SB_IsValidMsgId(CFE_SB_ValueToMsgId(MsgIdVal))); + if(MsgIdVal1 == 0 || MsgIdVal2 == 0) + { + /* Macro does not exist. Topic ID has not been implemented. */ + UtAssert_MIR("Topic ID has not been implemented. "); + } + else + { + UtAssert_BOOL_TRUE(ReturnCode1); + UtAssert_BOOL_TRUE(ReturnCode2); + } } void Test_CFE_SB_TlmTopicIdToMsgId(void) { - CFE_SB_MsgId_Atom_t MsgIdVal; + CFE_SB_MsgId_Atom_t MsgIdVal1; + CFE_SB_MsgId_Atom_t MsgIdVal2; + bool ReturnCode1 = false; + bool ReturnCode2 = false; + + MsgIdVal1 = CFE_SB_TlmTopicIdToMsgId(1, 1); + ReturnCode1 = CFE_SB_IsValidMsgId(CFE_SB_ValueToMsgId(MsgIdVal1)); - MsgIdVal = CFE_SB_TlmTopicIdToMsgId(1, 1); - UtAssert_BOOL_TRUE(CFE_SB_IsValidMsgId(CFE_SB_ValueToMsgId(MsgIdVal))); + MsgIdVal2 = CFE_SB_TlmTopicIdToMsgId(1, 0); + ReturnCode2 = CFE_SB_IsValidMsgId(CFE_SB_ValueToMsgId(MsgIdVal2)); - MsgIdVal = CFE_SB_CmdTopicIdToMsgId(1, 0); - UtAssert_BOOL_TRUE(CFE_SB_IsValidMsgId(CFE_SB_ValueToMsgId(MsgIdVal))); + if(MsgIdVal1 == 0 || MsgIdVal2 == 0) + { + /* Macro does not exist. Topic ID has not been implemented. */ + UtAssert_MIR("Topic ID has not been implemented. "); + } + else + { + UtAssert_BOOL_TRUE(ReturnCode1); + UtAssert_BOOL_TRUE(ReturnCode2); + } } void Test_CFE_SB_GlobalCmdTopicIdToMsgId(void) { CFE_SB_MsgId_Atom_t MsgIdVal; + bool ReturnCode = false; MsgIdVal = CFE_SB_GlobalCmdTopicIdToMsgId(2); - UtAssert_BOOL_TRUE(CFE_SB_IsValidMsgId(CFE_SB_ValueToMsgId(MsgIdVal))); + ReturnCode = CFE_SB_IsValidMsgId(CFE_SB_ValueToMsgId(MsgIdVal)); + if(MsgIdVal == 0) + { + /* Macro does not exist. Topic ID has not been implemented. */ + UtAssert_MIR("Topic ID has not been implemented. "); + } + else + { + UtAssert_BOOL_TRUE(ReturnCode); + } } void Test_CFE_SB_GlobalTlmTopicIdToMsgId(void) { CFE_SB_MsgId_Atom_t MsgIdVal; + bool ReturnCode = false; MsgIdVal = CFE_SB_GlobalTlmTopicIdToMsgId(2); - UtAssert_BOOL_TRUE(CFE_SB_IsValidMsgId(CFE_SB_ValueToMsgId(MsgIdVal))); + ReturnCode = CFE_SB_IsValidMsgId(CFE_SB_ValueToMsgId(MsgIdVal)); + if(MsgIdVal == 0) + { + /* Macro does not exist. Topic ID has not been implemented. */ + UtAssert_MIR("Topic ID has not been implemented. "); + } + else + { + UtAssert_BOOL_TRUE(ReturnCode); + } } void Test_CFE_SB_LocalCmdTopicIdToMsgId(void) { CFE_SB_MsgId_Atom_t MsgIdVal; + bool ReturnCode = false; MsgIdVal = CFE_SB_LocalCmdTopicIdToMsgId(3); - UtAssert_BOOL_TRUE(CFE_SB_IsValidMsgId(CFE_SB_ValueToMsgId(MsgIdVal))); + ReturnCode = CFE_SB_IsValidMsgId(CFE_SB_ValueToMsgId(MsgIdVal)); + if(MsgIdVal == 0) + { + /* Macro does not exist. Topic ID has not been implemented. */ + UtAssert_MIR("Topic ID has not been implemented. "); + } + else + { + UtAssert_BOOL_TRUE(ReturnCode); + } } void Test_CFE_SB_LocalTlmTopicIdToMsgId(void) { CFE_SB_MsgId_Atom_t MsgIdVal; + bool ReturnCode = false; MsgIdVal = CFE_SB_LocalTlmTopicIdToMsgId(3); - UtAssert_BOOL_TRUE(CFE_SB_IsValidMsgId(CFE_SB_ValueToMsgId(MsgIdVal))); + ReturnCode = CFE_SB_IsValidMsgId(CFE_SB_ValueToMsgId(MsgIdVal)); + if(MsgIdVal == 0) + { + /* Macro does not exist. Topic ID has not been implemented. */ + UtAssert_MIR("Topic ID has not been implemented. "); + } + else + { + UtAssert_BOOL_TRUE(ReturnCode); + } } /* From 31c84053228fe787a9a1749e78c89d6c9df2456a Mon Sep 17 00:00:00 2001 From: Maxime Haselbauer Date: Tue, 24 Sep 2024 19:10:56 +0200 Subject: [PATCH 2/3] Fix #2605 Pass the CMAKE_PREFIX_PATH to targets --- cmake/Makefile.sample | 4 ++++ cmake/mission_build.cmake | 1 + 2 files changed, 5 insertions(+) diff --git a/cmake/Makefile.sample b/cmake/Makefile.sample index c64668b8b..a56faf17b 100644 --- a/cmake/Makefile.sample +++ b/cmake/Makefile.sample @@ -115,6 +115,10 @@ ifneq ($(BUILDTYPE),) PREP_OPTS += -DCMAKE_BUILD_TYPE=$(BUILDTYPE) endif +ifneq ($(CMAKE_PREFIX_PATH),) +PREP_OPTS += -DCMAKE_PREFIX_PATH=$(CMAKE_PREFIX_PATH) +endif + all: $(MAKE) --no-print-directory -C "$(O)" mission-all diff --git a/cmake/mission_build.cmake b/cmake/mission_build.cmake index fad015d03..eff36900e 100644 --- a/cmake/mission_build.cmake +++ b/cmake/mission_build.cmake @@ -603,6 +603,7 @@ function(process_arch TARGETSYSTEM) -DMISSION_BINARY_DIR=${MISSION_BINARY_DIR} -DCMAKE_BUILD_TYPE=${CMAKE_BUILD_TYPE} -DCMAKE_INSTALL_PREFIX=${CMAKE_INSTALL_PREFIX} + -DCMAKE_PREFIX_PATH=${CMAKE_PREFIX_PATH} -DCMAKE_EXPORT_COMPILE_COMMANDS:BOOL=${CMAKE_EXPORT_COMPILE_COMMANDS} -DCFE_EDS_ENABLED_BUILD:BOOL=${CFE_EDS_ENABLED_BUILD} ${SELECTED_TOOLCHAIN_FILE} From d711bb554556b8771b6795f5c9eca91ff56ef333 Mon Sep 17 00:00:00 2001 From: Dylan Date: Thu, 3 Oct 2024 15:39:28 -0400 Subject: [PATCH 3/3] Updating documentation and version numbers for equuleus-rc1+dev205 --- CHANGELOG.md | 5 +++++ modules/core_api/fsw/inc/cfe_version.h | 2 +- 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 1fd77ed32..c43c54e68 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,10 @@ # Changelog +## Development Build: equuleus-rc1+dev205 +- fix sb coverage test failure +- Pass the CMAKE_PREFIX_PATH to targets +- See and + ## Development Build: equuleus-rc1+dev199 - Bump actions/download-artifact from 3 to 4.1.7 in /.github/workflows - See diff --git a/modules/core_api/fsw/inc/cfe_version.h b/modules/core_api/fsw/inc/cfe_version.h index 7e8c293da..f809f4153 100644 --- a/modules/core_api/fsw/inc/cfe_version.h +++ b/modules/core_api/fsw/inc/cfe_version.h @@ -26,7 +26,7 @@ #define CFE_VERSION_H /* Development Build Macro Definitions */ -#define CFE_BUILD_NUMBER 199 /**< @brief Development: Number of development git commits since CFE_BUILD_BASELINE */ +#define CFE_BUILD_NUMBER 205 /**< @brief Development: Number of development git commits since CFE_BUILD_BASELINE */ #define CFE_BUILD_BASELINE "equuleus-rc1" /**< @brief Development: Reference git tag for build number */ #define CFE_BUILD_DEV_CYCLE "equuleus-rc2" /**< @brief Development: Release name for current development cycle */ #define CFE_BUILD_CODENAME "Equuleus" /**< @brief: Development: Code name for the current build */