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

Function Wrapper

src/__tests__/renderHook.js:55–57  ·  view source on GitHub ↗
({children})

Source from the content-addressed store, hash-verified

53test('allows wrapper components', async () => {
54 const Context = React.createContext('default')
55 function Wrapper({children}) {
56 return <Context.Provider value="provided">{children}</Context.Provider>
57 }
58 const {result} = renderHook(
59 () => {
60 return React.useContext(Context)

Callers

nothing calls this directly

Calls 1

renderHookFunction · 0.90

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…