-
Notifications
You must be signed in to change notification settings - Fork 3k
GREENTEA: init trace if trace is enabled in json #11695
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
Conversation
@jeromecoutant, thank you for your changes. |
@@ -84,6 +84,10 @@ void _GREENTEA_SETUP_COMMON(const int timeout, const char *host_test_name, char | |||
} | |||
} | |||
|
|||
#ifdef MBED_CONF_MBED_TRACE_ENABLE | |||
mbed_trace_init(); |
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.
It might be seen as nice to have but not certain enabling trace would add also this call by default to greentea. It is known that this call needs to come from an app if tracing is used.
cc @SeppoTakalo
Mbed Trace API is a bit odd, as it does not automatically initialize itself. However, test cases are a bit different. There is common boilerplate that everyone follows. Pushing I think there is value on allowing traces to be turned on easily from test config. |
I'll run CI meanwhile (@jamesbeyond Please review) |
Test run: SUCCESSSummary: 11 of 11 test jobs passed |
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.
Look Good
Description
Hi
I was interested to enable mbed trace feature.
I can read that someone has to call the trace initialization function.
https://github.com/ARMmbed/mbed-os/blame/master/features/frameworks/mbed-trace/README.md#L56
Proposition is to init trace within GREENTEA_SETUP call.
Thx
Example of mbed_app.json:
Pull request type
Reviewers
Release Notes