-
Notifications
You must be signed in to change notification settings - Fork 27
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
feat: flexible choices for run_all_single_board_cases #282
Conversation
ffa19cb
to
bf46653
Compare
bf46653
to
aacd889
Compare
There are some unit test cases that use multiple groups and arguments to filter test cases, for example: [heap][mem_prot] and [test_env=noXtal32k]. So, I have added these options. |
aacd889
to
ea992d4
Compare
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.
some comments regarding api, overall the code LGTM.
dc78072
to
cbf9f30
Compare
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.
LGTM!
'-s', | ||
'--embedded-services', 'esp,idf', | ||
'--app-path', os.path.join(testdir.tmpdir, 'unit_test_app_esp32'), | ||
'--log-cli-level', 'DEBUG', |
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.
you're not checking the debug level in the test case, maybe remove the log cli level here?
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.
yes, sure
Co-authored-by: Fu Hanxi <[email protected]>
cbf9f30
to
07dcb19
Compare
The Unity test framework itself supports different inputs for choice tests. This merge request emulates this behavior to make it possible to control test choices with pytest-embedded.
The current ways to choose tests are:
For example:
dut.run_all_single_board_cases()
dut.run_all_single_board_cases(group="misc")
dut.run_all_single_board_cases(group="!misc")
dut.run_all_single_board_cases(names=["stack smashing protection CXX"])
addition examples:
dut.run_all_single_board_cases(group="heap,mem_prot") # [heap][mem_prot]
dut.run_all_single_board_cases(attributes={"test_env": "noXtal32k"}) # [test_env=noXtal32k]