mirror of
https://github.com/RGBCube/serenity
synced 2025-07-27 00:47:45 +00:00
LibJS: Provide 'details' key in results object for duplicate test
The test-js program expects this to exist for 'result: "fail"' results and would crash if any duplicated test(message) occurs, as we didn't provide 'details' in that case.
This commit is contained in:
parent
316e19c3ac
commit
1ea8d73628
1 changed files with 1 additions and 0 deletions
|
@ -429,6 +429,7 @@ class ExpectationError extends Error {
|
||||||
if (suite[message]) {
|
if (suite[message]) {
|
||||||
suite[message] = {
|
suite[message] = {
|
||||||
result: "fail",
|
result: "fail",
|
||||||
|
details: "Another test with the same message did already run",
|
||||||
};
|
};
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue