Conversation
ad6f973 to
7a1e444
Compare
| const verifyConditionCallback = (value: string) => new RegExp(/.*/.source + MAVEN_COMMAND_REGEX.source + /.*/.source + MAVEN_PLUGIN_RUN_REGEX.source).test(value); | ||
| const errorMessageCallback = (value: string) => `Output: ${value} doesn't contain exec-maven-plugin:exec command`; | ||
|
|
||
| myExtension.debugConsoleListeners.push({ |
There was a problem hiding this comment.
Please pass the listener instance to the callback; right now the topmost listener is cleared whatever it is. Also please clean the listener in a case that the launch process gets stuck and the listener never receives isMavenCommand().
Maybe listeners [] can be cleared in an afterEach() Mocha handler.
There was a problem hiding this comment.
Not sure what to you mean by pass the listener instance to the callback
There was a problem hiding this comment.
Not sure what to you mean by pass the listener instance to the callback
Sorry; in the ad6f973 version, the createDebugConsoleEventCallback pop-ed the last listener whatever it was. It would be more reliable if the listener actually registered by the test was pop-ed.
clearDebugConsoleListeners() solves it other way.
7a1e444 to
86bb663
Compare
86bb663 to
8e0a980
Compare
sdedic
left a comment
There was a problem hiding this comment.
Looks good. Not needed at the moment (for the current usage in tests), but consider passing some bit of context, i.e. DebugSession to the DebugConsoleListener callback: now the tracker attaches Adapter to each DebugSession, but the info which debug session produces the message is lost before the output reach registered listeners.
|
fixing milestone as not yet branched |
Micronaut launcher tests that are testing commands exposed through code lenses -
nbls.run.single(run and run in dev mode) andnbls.debug.single