Skip to content

Commit 0b2c253

Browse files
committed
Temporarily improve error message to understand reason for test failure
1 parent 54664a2 commit 0b2c253

File tree

1 file changed

+5
-1
lines changed
  • packages/nextjs/test/integration/test/utils

1 file changed

+5
-1
lines changed

packages/nextjs/test/integration/test/utils/client.js

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -99,7 +99,11 @@ const extractEnvelopeFromRequest = request => {
9999

100100
const assertObjectMatches = (actual, expected) => {
101101
if (Object.prototype.toString.call(actual) !== Object.prototype.toString.call(expected)) {
102-
throw new TypeError(`Types mismatch: ${actual} !== ${expected}`);
102+
throw new TypeError(
103+
`Types mismatch: ${actual} !== ${expected}. Actual (full): ${JSON.stringify(
104+
actual ?? '',
105+
)} Expected (full): ${JSON.stringify(expected)}`,
106+
);
103107
}
104108

105109
for (const key in expected) {

0 commit comments

Comments
 (0)