numaru / vscode-ceedling-test-adapter

Ceedling Test Adapter for the VS Code Test Explorer
MIT License
37 stars 13 forks source link

project.yml env variables support #132

Open WJKPK opened 6 months ago

WJKPK commented 6 months ago

During the development of a project that requires the setup of an environment-dependent build path, I encountered a minor issue. When the build_root in project.yml is configured with the following statement in the project.yml file:

  :build_root: "#{ENV['BUILD_DIR']}/unit-tests"

an anomaly is observed in the test result icons, which appear as warnings, regardless of the actual test results. You can see an example screenshot here: Screenshot from 2024-02-12 15-14-42 Even when the test results are positive, as indicated in the test summary:

Test 'test_lcd_manager.c'
-------------------------
Running test_lcd_manager.out...

--------------------
OVERALL TEST SUMMARY
--------------------
TESTED:  3
PASSED:  3
FAILED:  0
IGNORED: 0

It appears that Ruby expressions similar to the one mentioned above are officially supported in Ceedling. An example can be found in the Ceedling blinky project. However, it seems that this syntax is not supported in the test adapter. To address this, a patch has been created. Does this code meet the requirements to be merged into the project? Should I make any changes before submitting a pull request? EDIT: Already created PR for convenience #133

A big thanks in advance for the feedback!