-
Notifications
You must be signed in to change notification settings - Fork 202
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fix #1266, use events for CFE test asserts
Reports test failures as CFE events, which allows for more processing capability, and allows failures to be recieved externally (e.g. ground system).
- Loading branch information
Showing
7 changed files
with
219 additions
and
61 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,12 +1,14 @@ | ||
project(CFE_ASSERT C) | ||
|
||
include_directories("${CFE_ASSERT_SOURCE_DIR}/inc") | ||
include_directories("${UT_ASSERT_SOURCE_DIR}/inc") | ||
|
||
# Create the app module | ||
add_cfe_app(cfe_assert | ||
src/cfe_assert_io.c | ||
src/cfe_assert_init.c | ||
$<TARGET_OBJECTS:ut_assert_pic> | ||
) | ||
|
||
# publicize the interface to cfe_assert (and ut_assert) | ||
target_include_directories(cfe_assert PUBLIC | ||
${CFE_ASSERT_SOURCE_DIR}/inc | ||
$<TARGET_PROPERTY:ut_assert,INTERFACE_INCLUDE_DIRECTORIES> | ||
) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,59 @@ | ||
/************************************************************************* | ||
** | ||
** GSC-18128-1, "Core Flight Executive Version 6.7" | ||
** | ||
** Copyright (c) 2006-2019 United States Government as represented by | ||
** the Administrator of the National Aeronautics and Space Administration. | ||
** All Rights Reserved. | ||
** | ||
** Licensed under the Apache License, Version 2.0 (the "License"); | ||
** you may not use this file except in compliance with the License. | ||
** You may obtain a copy of the License at | ||
** | ||
** http://www.apache.org/licenses/LICENSE-2.0 | ||
** | ||
** Unless required by applicable law or agreed to in writing, software | ||
** distributed under the License is distributed on an "AS IS" BASIS, | ||
** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
** See the License for the specific language governing permissions and | ||
** limitations under the License. | ||
** | ||
** File: cfe_assert.h | ||
** | ||
** Purpose: | ||
** Specification for the CFE assert (UT assert wrapper) functions. | ||
** | ||
*************************************************************************/ | ||
|
||
/** | ||
* @file | ||
* | ||
* Internal Declarations and prototypes for cfe_assert module | ||
*/ | ||
|
||
#ifndef CFE_ASSERT_PRIV_H | ||
#define CFE_ASSERT_PRIV_H | ||
|
||
/************************************************************************ | ||
** Includes | ||
*************************************************************************/ | ||
#include "common_types.h" | ||
#include "cfe_assert.h" | ||
|
||
/************************************************************************ | ||
** Type Definitions | ||
*************************************************************************/ | ||
|
||
typedef struct | ||
{ | ||
uint32 CurrVerbosity; | ||
|
||
/** | ||
* Function to invoke to report test status | ||
*/ | ||
CFE_Assert_StatusCallback_t StatusCallback; | ||
} CFE_Assert_Global_t; | ||
|
||
extern CFE_Assert_Global_t CFE_Assert_Global; | ||
|
||
#endif /* CFE_ASSERT_PRIV_H */ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,10 +1,13 @@ | ||
project(CFE_TESTRUNNER C) | ||
|
||
include_directories("inc") | ||
include_directories("${UT_ASSERT_SOURCE_DIR}/inc") | ||
|
||
# Create the app module | ||
add_cfe_app(cfe_testrunner | ||
src/cfe_testrunner_main.c | ||
) | ||
|
||
target_include_directories(cfe_testrunner PUBLIC | ||
${CFE_TESTRUNNER_SOURCE_DIR}/inc | ||
) | ||
|
||
# register the dependency on cfe_assert | ||
add_cfe_app_dependency(cfe_testrunner cfe_assert) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters