-
Notifications
You must be signed in to change notification settings - Fork 161
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
Expose 'disabled' and 'pending' statuses to let reporter differentiate them #129
Comments
Depending issue in WebStorm: https://youtrack.jetbrains.com/issue/WEB-22696 |
@segrey what about add only one value |
@maksimr no particular preferences here. Any way that allows to differentiate |
But it's better if sometimes in future jasmine will add new status we should not change the source code. |
@maksimr if I understand you correctly, you suggest to have |
As for in what way karma API should be extended, this question is still open for me. Options:
I'd slightly lean to the first option as it's a smaller API change. Other options and thoughts are welcome. |
feat: report status of the spec closes #129
Thanks for the fix, now |
Jasmine exposes
'disabled'
and'pending'
statuses via specResult.status.IIUC,
specResult.disabled === true
means that there is at least one focused spec (fdescribe/fit
) and this spec is not declared as focused.specResult.pending === true
means that this spec is declared as pending (xdescribe/xit
or without a function body).Currently, karma-jasmine merges both these statuses into
skipped
(https://github.com/karma-runner/karma-jasmine/blob/v1.0.2/src/adapter.js#L214) making it impossible for a reporter to handle these statuses differently. E.g. for IDE reporter, it would be convenient to show pending specs in a result test tree conditionally (e.g. if "Show Pending" is enabled) and hide disabled spec always.Would be great if a reporter could access
result.disabled
andresult.pending
values inonSpecComplete(browser, result)
.Thanks!
The text was updated successfully, but these errors were encountered: