Skip to content

Commit

Permalink
Fix unit tests.
Browse files Browse the repository at this point in the history
Signed-off-by: Timothy Rule (VM/EMT3) <[email protected]>
  • Loading branch information
timrulebosch committed Nov 29, 2024
1 parent fcd8112 commit a0d4a33
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 4 deletions.
10 changes: 8 additions & 2 deletions tests/cmocka/fmu/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -105,7 +105,13 @@ target_link_libraries(test_fmu
install(TARGETS test_fmu)
install(
FILES
data/modelDescription.xml
DESTINATION
data
data/test_fmu
)
install(
FILES
data/modelDescription.xml
DESTINATION
data/test_fmu/resources
)

3 changes: 1 addition & 2 deletions tests/cmocka/fmu/test_signals.c
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ int test_fmu_default_signal_setup(void** state)
hashmap_init(&fmu->variables.binary.decode_func);
fmu_load_signal_handlers(fmu);

fmu->instance.resource_location = (char*)"../../fmu/data/resources";
fmu->instance.resource_location = (char*)"data/test_fmu/resources";

*state = fmu;
return 0;
Expand Down Expand Up @@ -119,7 +119,6 @@ void test_fmu_default_signals_reset(void** state)
fmu->variables.vtable.setup(fmu);

assert_non_null(fmu->data);
FmuSignalVector* sv = fmu->data;

FmuSignalVectorIndex* idx_i = hashmap_get(&fmu->variables.binary.rx, "4");
FmuSignalVectorIndex* idx_o = hashmap_get(&fmu->variables.binary.tx, "5");
Expand Down

0 comments on commit a0d4a33

Please sign in to comment.