Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

cFE Integration candidate: 2021-08-10 #1772

Merged
merged 33 commits into from
Aug 11, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
33 commits
Select commit Hold shift + click to select a range
2db8161
Fix #1727, mistakes in some copyright headers
Jul 29, 2021
5dcefac
Fix #1730, Move global count into test global struct.
zanzaben Jul 30, 2021
961d4eb
Fix #1743, update coverage test to use UtAssert macros
jphickey Jul 30, 2021
3177426
Fix #1685, Add table registration functional tests
nmullane Jul 28, 2021
7e854ff
Fix #1688, Add table information functional tests
nmullane Jul 29, 2021
9aa907a
Fix #1686, Add manage table content functional tests
nmullane Jul 30, 2021
343e0d0
Fix #1687, Add access table content functional tests
nmullane Aug 2, 2021
33f66a9
Fix #813, Add Generic Counter API test
jphickey Jul 30, 2021
31548d4
Fix #1733, instantiate global once.
zanzaben Aug 4, 2021
f1db90c
Fix #806, Add application control functional tests
nmullane Jul 28, 2021
e07f222
Fix #1763, last char truncated in coverage log output
jphickey Aug 4, 2021
18a9295
Fix #1644, finish ES misc API functional test
nmullane Aug 5, 2021
0484d64
Merge pull request #1737 from zanzaben/fix1733_move_global_into_struct
astrogeco Aug 6, 2021
da12938
Merge pull request #1722 from nmullane/fix806-es-application-control-…
astrogeco Aug 6, 2021
d47b56c
Fix #1645, Add resource ID API functional tests
nmullane Jul 27, 2021
95349ed
Merge pull request #1744 from jphickey/fix-1743-utassert-macros
astrogeco Aug 9, 2021
392a242
Update #813, add UtPrintf for APIs being called
jphickey Aug 9, 2021
9b634da
Merge pull request #1734 from nmullane/table-api-functional-tests
astrogeco Aug 9, 2021
600fd7a
Merge pull request #1753 from jphickey/fix-813-counter-tests
astrogeco Aug 9, 2021
e7166d0
Merge pull request #1716 from nmullane/fix1645-es-resource-id-functio…
astrogeco Aug 9, 2021
4c91565
Merge pull request #1766 from nmullane/fix1644-finish-es-misc-api-fun…
astrogeco Aug 9, 2021
84bb9d7
Merge pull request #1764 from jphickey/fix-1763-covtest-printf-log
astrogeco Aug 9, 2021
7e5e4e5
Merge pull request #1728 from pavll/fix-1727-correct-some-file-headers
astrogeco Aug 9, 2021
e6979cf
Fix #1692, Add misc time api functional test
nmullane Aug 5, 2021
f8ceda1
Merge pull request #1767 from nmullane/fix1692-misc-time-functional-t…
astrogeco Aug 10, 2021
3f5abd9
Fix #1649, Add Functional Test for EVS Reset Filters API.
zanzaben Aug 2, 2021
3f2ee86
Fix #1649, Add comment for logic dependency
zanzaben Aug 10, 2021
33f3505
Merge pull request #1749 from zanzaben/fix1649_EVS_Reset_Filters_Func…
astrogeco Aug 10, 2021
676c473
Fix #1774, replace VOIDCALL assert macro
jphickey Aug 10, 2021
20fbd6f
Fix #1780, Resolve RTEMS CFE_FT_Global build fail
astrogeco Aug 9, 2021
25112ec
Merge pull request #1796 from jphickey/fix-1774-replace-voidcall-macro
astrogeco Aug 10, 2021
c16b7ae
Merge pull request #1781 from astrogeco/1780-RTEMS-build-failure
astrogeco Aug 10, 2021
a1b4529
IC:2021-08-10, Bump to v6.8.0-rc1+dev844
astrogeco Aug 11, 2021
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
32 changes: 24 additions & 8 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,22 @@ The detailed cFE user's guide can be viewed at <https://github.com/nasa/cFS/blob

## Version History

### Development Build: v6.8.0-rc1+dev844

- Move global count into test global struct
- Add ES application control API functional tests
- Add null pointer check to CFE_ES_ReloadApp functional test
- Add Generic Counter API test
- Update coverage test to use UtAssert macros
- Add resource ID API functional tests
- Fix last char truncated in coverage log output
- Fix typos in some copyright headers
- Add misc time api functional test
- Add Functional Test for EVS Reset Filters API
- Replace cFE_FTAssert_VOIDCALL with new UtAssert_VOIDCALL
- Remove multiple instantiations of CFE_FT_Global
- Add functional tests for cFE Table APIs

### Development Build: v6.8.0-rc1+dev810

- Add null pointer check to table GetAddresses and ReleaseAddresses
Expand Down Expand Up @@ -252,19 +268,19 @@ Updates the doxygen documentation for this parameter, as it was incorrectly spec
### Development Build: v6.8.0-rc1+dev402

- HOTFIX 20210312, updates to work with older CMake
- Fix #972, reorganize directory structure
- reorganize directory structure
- HOTFIX IC 2021-03-05: Correct static app build issue
- See <https://github.com/nasa/cFE/pull/1222>

### Development Build: v6.8.0-rc1+dev392

- Fix #665, update pipe name documentation.
- Fix #1165, remove configs about shells
- Fix #1094, Update CRC documentation
- Fix #979, add stack size and priority to task info …
- Fix #1170, refactor target config objects …
- Fix #1207, Add wrapper targets to simplify app builds …
- Fix #1211, Add Testing Tools to the Security Policy
- update pipe name documentation.
- remove configs about shells
- Update CRC documentation
- add stack size and priority to task info …
- refactor target config objects …
- Add wrapper targets to simplify app builds …
- Add Testing Tools to the Security Policy
- See <https://github.com/nasa/cFE/pull/1213>

### Development Build: v6.8.0-rc1+dev382
Expand Down
2 changes: 1 addition & 1 deletion modules/cfe_assert/src/cfe_assert_init.c
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
** See the License for the specific language governing permissions and
** limitations under the License.
**
** File: cfe_assert_main.c
** File: cfe_assert_init.c
**
** Purpose:
** Implementation of the CFE assert (UT assert wrapper) functions.
Expand Down
2 changes: 1 addition & 1 deletion modules/cfe_assert/src/cfe_assert_priv.h
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
** See the License for the specific language governing permissions and
** limitations under the License.
**
** File: cfe_assert.h
** File: cfe_assert_priv.h
**
** Purpose:
** Specification for the CFE assert (UT assert wrapper) functions.
Expand Down
2 changes: 1 addition & 1 deletion modules/cfe_assert/src/cfe_assert_runner.c
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
** See the License for the specific language governing permissions and
** limitations under the License.
**
** File: cfe_testrunner_main.c
** File: cfe_assert_runner.c
**
** Purpose:
** Implementation of the CFE testrunner (UT testrunner wrapper) functions.
Expand Down
15 changes: 14 additions & 1 deletion modules/cfe_testcase/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -1,21 +1,34 @@
include_directories(inc)

# Filenames based on doxygen groups.
# Create the app module
add_cfe_app(cfe_testcase
add_cfe_app(cfe_testcase
src/cfe_test.c
src/cfe_test_table.c
src/es_application_control_test.c
src/es_info_test.c
src/es_task_test.c
src/es_cds_test.c
src/es_counter_test.c
src/es_misc_test.c
src/es_mempool_test.c
src/es_resource_id_test.c
src/evs_filters_test.c
src/evs_send_test.c
src/fs_header_test.c
src/fs_util_test.c
src/message_id_test.c
src/sb_pipe_mang_test.c
src/tbl_content_access_test.c
src/tbl_content_mang_test.c
src/tbl_information_test.c
src/tbl_registration_test.c
src/time_arithmetic_test.c
src/time_current_test.c
src/time_conversion_test.c
src/time_misc_test.c
)

# register the dependency on cfe_assert
add_cfe_app_dependency(cfe_testcase cfe_assert)
add_cfe_tables(cfeTestAppTable tables/cfe_test_tbl.c)
46 changes: 46 additions & 0 deletions modules/cfe_testcase/inc/cfe_test_tbl.h
Original file line number Diff line number Diff line change
@@ -0,0 +1,46 @@
/*************************************************************************
**
** 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_test_table.h
**
** Purpose:
** CFE Test Table struct definition
**
*************************************************************************/

/**
* @file
*
* CFE Test Table struct definition
*/

#ifndef CFE_TEST_TBL_H
#define CFE_TEST_TBL_H

/*
* Test table structure
*/
typedef struct
{
uint16 Int1;
uint16 Int2;
} TBL_TEST_Table_t;

#endif /* CFE_TEST_TBL_H */
16 changes: 16 additions & 0 deletions modules/cfe_testcase/src/cfe_test.c
Original file line number Diff line number Diff line change
Expand Up @@ -33,12 +33,19 @@
#include "cfe_assert.h"
#include "cfe_test.h"

CFE_FT_Global_t CFE_FT_Global;

/*
* Test main function
* Register this test routine with CFE Assert
*/
void CFE_TestMain(void)
{
/* Constant Table information used by all table tests */
CFE_FT_Global.TblName = "TestTable";
CFE_FT_Global.RegisteredTblName = "CFE_TEST_APP.TestTable";
CFE_FT_Global.TblFilename = "test_tbl.tbl";

/*
* Register this test app with CFE assert
*
Expand All @@ -51,19 +58,28 @@ void CFE_TestMain(void)
/*
* Register test cases in UtAssert
*/
ESApplicationControlTestSetup();
ESCDSTestSetup();
ESCounterTestSetup();
ESInfoTestSetup();
ESMemPoolTestSetup();
ESMiscTestSetup();
ESResourceIDTestSetup();
ESTaskTestSetup();
EVSFiltersTestSetup();
EVSSendTestSetup();
FSHeaderTestSetup();
FSUtilTestSetup();
MessageIdTestSetup();
SBPipeMangSetup();
TBLContentAccessTestSetup();
TBLContentMangTestSetup();
TBLInformationTestSetup();
TBLRegistrationTestSetup();
TimeArithmeticTestSetup();
TimeCurrentTestSetup();
TimeConversionTestSetup();
TimeMiscTestSetup();

/*
* Execute the tests
Expand Down
26 changes: 22 additions & 4 deletions modules/cfe_testcase/src/cfe_test.h
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
** See the License for the specific language governing permissions and
** limitations under the License.
**
** File: cfe_test.c
** File: cfe_test.h
**
** Purpose:
** Initialization routine for CFE functional test
Expand All @@ -39,15 +39,27 @@
* Includes
*/
#include "cfe.h"
#include "cfe_test_tbl.h"

#include "uttest.h"
#include "utassert.h"

typedef struct
{
CFE_FS_FileWriteMetaData_t FuncTestState;

/* Generic utility counter */
int Count;

/* Table information used by all table tests */
CFE_TBL_Handle_t TblHandle;
const char * TblName;
const char * RegisteredTblName;
const char * TblFilename;
} CFE_FT_Global_t;

extern CFE_FT_Global_t CFE_FT_Global;

/**
* Name of log file to write
*
Expand All @@ -74,24 +86,30 @@ typedef struct
UtAssert_True(rcact < CFE_SUCCESS, "%s == (%ld) ", #actual, (long)rcact); \
} while (0)

/* Log calls to void functions */
#define cFE_FTAssert_VOIDCALL(func) (func, UtAssert(true, #func, __FILE__, __LINE__))

bool TimeInRange(CFE_TIME_SysTime_t Time, CFE_TIME_SysTime_t Target, OS_time_t difference);

void CFE_TestMain(void);
void ESApplicationControlTestSetup(void);
void ESCDSTestSetup(void);
void ESCounterTestSetup(void);
void ESInfoTestSetup(void);
void ESMemPoolTestSetup(void);
void ESMiscTestSetup(void);
void ESResourceIDTestSetup(void);
void ESTaskTestSetup(void);
void EVSFiltersTestSetup(void);
void EVSSendTestSetup(void);
void FSHeaderTestSetup(void);
void FSUtilTestSetup(void);
void MessageIdTestSetup(void);
void SBPipeMangSetup(void);
void TBLContentAccessTestSetup(void);
void TBLContentMangTestSetup(void);
void TBLInformationTestSetup(void);
void TBLRegistrationTestSetup(void);
void TimeArithmeticTestSetup(void);
void TimeCurrentTestSetup(void);
void TimeConversionTestSetup(void);
void TimeMiscTestSetup(void);

#endif /* CFE_TEST_H */
49 changes: 49 additions & 0 deletions modules/cfe_testcase/src/cfe_test_table.c
Original file line number Diff line number Diff line change
@@ -0,0 +1,49 @@
/*************************************************************************
**
** 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_test_table.c
**
** Purpose:
** Initialization of variables used by table functional tests and
** function definitions for setup and teardown table functions
**
*************************************************************************/

/*
* Includes
*/

#include "cfe_test.h"
#include "cfe_test_table.h"

/* Setup function to register a table */
void RegisterTestTable(void)
{

UtAssert_INT32_EQ(CFE_TBL_Register(&CFE_FT_Global.TblHandle, CFE_FT_Global.TblName, sizeof(TBL_TEST_Table_t),
CFE_TBL_OPT_DEFAULT, NULL),
CFE_SUCCESS);
}

/* Teardown function to unregister a table */
void UnregisterTestTable(void)
{
UtAssert_INT32_EQ(CFE_TBL_Unregister(CFE_FT_Global.TblHandle), CFE_SUCCESS);
}
45 changes: 45 additions & 0 deletions modules/cfe_testcase/src/cfe_test_table.h
Original file line number Diff line number Diff line change
@@ -0,0 +1,45 @@
/*************************************************************************
**
** 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_test_table.h
**
** Purpose:
** Declare global struct variable and function prototypes for table tests
**
*************************************************************************/

/**
* @file
*
* Declarations and prototypes for cfe_test module table tests
*/

#ifndef CFE_TEST_TABLE_H
#define CFE_TEST_TABLE_H

/*
* Includes
*/
#include "cfe_test.h"

void RegisterTestTable(void);
void UnregisterTestTable(void);

#endif /* CFE_TEST_TABLE_H */
Loading