-
Notifications
You must be signed in to change notification settings - Fork 29
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
promises support in tests #307
base: feature/mocha-test-reporter
Are you sure you want to change the base?
Conversation
…pile invalid output
return m.onTestSuiteComplete() | ||
end if | ||
|
||
rooibos.common.logDebug("Running suite asynchronously!") |
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.
update this message
if m.testSuite.isNodeTest | ||
m.markDoneWhenTestCompletes(promise) | ||
else | ||
throw "Can not return a promise from a non-node test" |
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.
Double check that this is a safe way to fail the test and have it show as crashed test.
@@ -159,27 +159,16 @@ namespace rooibos | |||
m.nodeContext.testRunner = m | |||
m.nodeContext.top.addFields({ | |||
"rooibosSuiteFinished": false |
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.
We can remove this field as well due to watching for the test results now.
FileFactory
to import rooibosroku_modules
@async
is present and@sgnode
annotation isn't we should default to usingNode
m.done()