Skip to content

Commit

Permalink
Don't use inline snapshot
Browse files Browse the repository at this point in the history
  • Loading branch information
poteto committed Apr 24, 2023
1 parent bc71707 commit df3e480
Showing 1 changed file with 4 additions and 13 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -654,19 +654,10 @@ describe('ReactHooksInspectionIntegration', () => {
const tree = ReactDebugTools.inspectHooksOfFiber(childFiber);

expect(tree.length).toEqual(1);
expect(tree[0]).toMatchInlineSnapshot(`
{
"id": 0,
"isStateEditable": false,
"name": "MemoCache",
"subHooks": [],
"value": [
<div>
1
</div>,
],
}
`);
expect(tree[0].isStateEditable).toBe(false);
expect(tree[0].name).toBe('MemoCache');
expect(tree[0].value).toHaveLength(1);
expect(tree[0].value[0]).toEqual(<div>{1}</div>);
});

describe('useDebugValue', () => {
Expand Down

0 comments on commit df3e480

Please sign in to comment.