tests/build_system: add test for relative paths - #22667
Open
basilfx wants to merge 2 commits into
Open
Conversation
basilfx
requested review from
MichelRottleuthner,
aabadie and
leandrolanzieri
as code owners
September 6, 2026 12:59
Member
Author
crasbe
reviewed
Sep 6, 2026
| ## Introduction | ||
|
|
||
| This test is supposed to check if `__FILE__` evaluates to the desired value, | ||
| which should evaluate to the path of a filename relative to `$(RIOTBASE)`. The |
Contributor
There was a problem hiding this comment.
Suggested change
| which should evaluate to the path of a filename relative to `$(RIOTBASE)`. The | |
| which should resolve to the path of a filename relative to `$(RIOTBASE)`. The |
Perhaps?
| * @brief __FILE__ test application | ||
| * | ||
| * @author Kaspar Schleiser <kaspar@schleiser.de> | ||
| * |
Contributor
There was a problem hiding this comment.
Suggested change
| * |
That's from riotgen as far as I know, but we can still save a line :)
| int main(void) | ||
| { | ||
| printf("__FILE__: %s\n", __FILE__); | ||
|
|
Member
Author
|
This isn't working on CI, because of
When you run the follwing from within I have two options:
|
This file contains hidden or 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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Contribution description
Going through the list of (old) issues, I came across #14262. I believe that issue isn't completely relevant anymore, after #18913 got merged.
Nonetheless, #18913 did not add a test, which #14262 did. I think the test still adds value.
Testing procedure
Run
make -C tests/build_system/relpath all testand it should pass.Issues/PRs references
#14262, #18913
Declaration of AI-Tools / LLMs usage:
AI-Tools / LLMs that were used are: