-
Notifications
You must be signed in to change notification settings - Fork 2k
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
[RFC] tests: group applications in subdirectories #15358
Changes from all commits
28e631b
70b2741
b45b426
061c837
7ea6ad5
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -3,16 +3,55 @@ | |
# fallback so empty RIOTBASE won't lead to "/examples/" | ||
RIOTBASE ?= . | ||
|
||
# Define the list of examples subdirectories that contain application directories | ||
EXAMPLES_APPLICATIONS_SUBDIRS := \ | ||
ble \ | ||
coap \ | ||
cord \ | ||
dtls \ | ||
gnrc \ | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I think this could change with the discussion below, but I'm not sure if adding For instance, where would we put GNRC LoRaWAN? There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Sorry, I just saw #15358 (comment). But in any case, I still think it would be better to have a more "functional" name than I think it would make sense something like:
or something like that There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Keep in mind that one day some applications in the tests might arrive in the I fear that it will be impossible to find an organization that fits everyone vision and that this discussion will be endless. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. ok, I see your point and agree. I also agree that this wouldn't replace documentation There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
I agree here, a first step is having an organization, moving that organization around should be easier once the initial change is in. |
||
icn \ | ||
lorawan \ | ||
mqtt \ | ||
posix \ | ||
# | ||
EXAMPLES_APPLICATIONS_SUBDIRS := $(addprefix examples/,$(EXAMPLES_APPLICATIONS_SUBDIRS)) | ||
|
||
# Define the list of tests sudirectories that contain application directories | ||
TEST_APPLICATIONS_SUBDIRS := \ | ||
arch \ | ||
bench \ | ||
boards \ | ||
bootloaders \ | ||
build_system \ | ||
core \ | ||
cpp \ | ||
drivers \ | ||
periph \ | ||
pkg \ | ||
sys \ | ||
sys/net \ | ||
# | ||
TEST_APPLICATIONS_SUBDIRS := $(addprefix tests/,$(TEST_APPLICATIONS_SUBDIRS)) | ||
|
||
# Prepare the list of application directories | ||
APPLICATION_DIRS := \ | ||
fuzzing \ | ||
bootloaders \ | ||
examples \ | ||
tests \ | ||
$(EXAMPLES_APPLICATIONS_SUBDIRS) \ | ||
$(TEST_APPLICATIONS_SUBDIRS) \ | ||
# | ||
|
||
# 1. use wildcard to find Makefiles | ||
# 2. use patsubst to drop trailing "/" | ||
# 3. use patsubst to drop possible leading "./" | ||
# 4. sort | ||
APPLICATION_DIRS := $(sort $(patsubst ./%,%,$(patsubst %/,%,$(dir $(wildcard \ | ||
$(RIOTBASE)/fuzzing/*/Makefile \ | ||
$(RIOTBASE)/bootloaders/*/Makefile \ | ||
$(RIOTBASE)/examples/*/Makefile \ | ||
$(RIOTBASE)/tests/*/Makefile \ | ||
))))) | ||
APPLICATION_DIRS := $(addprefix $(RIOTBASE)/,$(APPLICATION_DIRS)) | ||
APPLICATION_DIRS_RELATIVE := $(dir $(wildcard $(addsuffix /*/Makefile,$(APPLICATION_DIRS)))) | ||
APPLICATION_DIRS_ABSOLUTE := $(abspath $(APPLICATION_DIRS_RELATIVE)) | ||
APPLICATION_DIRS := $(sort $(patsubst ./%,%,$(patsubst %/,%,$(APPLICATION_DIRS_RELATIVE)))) | ||
|
||
info-applications: | ||
@for dir in $(APPLICATION_DIRS); do echo $$dir; done | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Wouldn't this be screaming in the face of every user of an application built out of tree?