nasa / osal

The Core Flight System (cFS) Operating System Abstraction Layer (OSAL)
Apache License 2.0
546 stars 213 forks source link

Draft: [#1478] Initial demo of self registration of tests for ut_assert. #1479

Closed thesamprice closed 1 day ago

thesamprice commented 5 days ago

Still needs cleaned up, but wanted to demo the possibility More concerned if i could, than if i should.

Only got this working for 1 test, would need more cleanup.

mkdir build_osal_test
cd build_osal_test
cmake -DENABLE_UNIT_TESTS=true -DOSAL_SYSTEM_BSPTYPE=generic-linux -DOSAL_CONFIG_DEBUG_PERMISSIVE_MODE=TRUE ..

make bin-sem-test
./tests/bin-sem-test

Checklist (Please check before submitting)

Describe the contribution A clear and concise description of what the contribution is.

Testing performed Steps taken to test the contribution:

  1. Build steps '...'
  2. Execution steps '...'

Expected behavior changes A clear and concise description of how this contribution will change behavior and level of impact.

System(s) tested on

Additional context Add any other context about the contribution here.

Third party code If included, identify any third party code and provide text file of license

Contributor Info - All information REQUIRED for consideration of pull request Full name and company/organization/center of all contributors ("Personal" if individual work)

thesamprice commented 5 days ago

Debugging included dumping the section, and looking at the marker to determine that it was padding out memory.

objdump -s -j .utest_records tests/bin-sem-test
thesamprice commented 1 day ago

Closing MR, this is probably not portable with linker scripts.