MCPcopy
hub / github.com/testing-library/react-testing-library / HelloWorld

Function HelloWorld

src/__tests__/debug.js:13–20  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

11
12test('debug pretty prints the container', () => {
13 const HelloWorld = () => <h1>Hello World</h1>
14 const {debug} = render(<HelloWorld />)
15 debug()
16 expect(console.log).toHaveBeenCalledTimes(1)
17 expect(console.log).toHaveBeenCalledWith(
18 expect.stringContaining('Hello World'),
19 )
20})
21
22test('debug pretty prints multiple containers', () => {
23 const HelloWorld = () => (

Callers

nothing calls this directly

Calls 1

renderFunction · 0.85

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…