diff --git a/packages/react-debug-tools/src/__tests__/ReactHooksInspection-test.js b/packages/react-debug-tools/src/__tests__/ReactHooksInspection-test.js index 63e44dfbe1005..79c1261c3b063 100644 --- a/packages/react-debug-tools/src/__tests__/ReactHooksInspection-test.js +++ b/packages/react-debug-tools/src/__tests__/ReactHooksInspection-test.js @@ -584,24 +584,29 @@ describe('ReactHooksInspection', () => { return
{value}
; } const tree = ReactDebugTools.inspectHooks(Foo, {}); - expect(normalizeSourceLoc(tree)).toMatchInlineSnapshot(` - [ - { - "debugInfo": null, - "hookSource": { - "columnNumber": 0, - "fileName": "**", - "functionName": "Foo", - "lineNumber": 0, - }, - "id": null, - "isStateEditable": false, - "name": "Unresolved", - "subHooks": [], - "value": Promise {}, + const results = normalizeSourceLoc(tree); + expect(results).toHaveLength(1); + expect(results[0]).toMatchInlineSnapshot( + { + value: expect.any(Promise), + }, + ` + { + "debugInfo": null, + "hookSource": { + "columnNumber": 0, + "fileName": "**", + "functionName": "Foo", + "lineNumber": 0, }, - ] - `); + "id": null, + "isStateEditable": false, + "name": "Unresolved", + "subHooks": [], + "value": Any, + } + `, + ); }); describe('useDebugValue', () => {