You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
We have run into cases of trying to log a JavaScript object, without stringifying it. The master json file seems to be generated fine, but the html file is not generated. For example, when logging:
"foobar string"
and
{foobar: object}
the events part of the JSON for the test looks like:
so my presumption is that this causes something to go wrong when writing the HTML, but not the JSON.
We are using process.emit("test:log", message) to add to the log, as one step in a custom logging method that does some other things at the same time (console log, allure steps, etc). If there is a more proper way to log things like this that would bypass this issue, I'd be happy to change our implementation. I would just JSON.stringify() everything but I don't want to lose nuance for things that aren't JSON (like NaN, Infinity, etc).
At a minimum, something to surface the error to the user would be nice rather than failing silently.
The text was updated successfully, but these errors were encountered:
We have run into cases of trying to log a JavaScript object, without stringifying it. The master json file seems to be generated fine, but the
html
file is not generated. For example, when logging:and
the
events
part of the JSON for the test looks like:so my presumption is that this causes something to go wrong when writing the HTML, but not the JSON.
We are using
process.emit("test:log", message)
to add to the log, as one step in a custom logging method that does some other things at the same time (console log, allure steps, etc). If there is a more proper way to log things like this that would bypass this issue, I'd be happy to change our implementation. I would justJSON.stringify()
everything but I don't want to lose nuance for things that aren't JSON (likeNaN
,Infinity
, etc).At a minimum, something to surface the error to the user would be nice rather than failing silently.
The text was updated successfully, but these errors were encountered: