MCPcopy Create free account
hub / github.com/BetaSu/big-react / toMatchRenderedOutput

Function toMatchRenderedOutput

scripts/jest/reactTestMatchers.js:32–41  ·  view source on GitHub ↗
(ReactNoop, expectedJSX)

Source from the content-addressed store, hash-verified

30}
31
32function toMatchRenderedOutput(ReactNoop, expectedJSX) {
33 if (typeof ReactNoop.getChildrenAsJSX === 'function') {
34 const Scheduler = ReactNoop._Scheduler;
35 assertYieldsWereCleared(Scheduler);
36 return captureAssertion(() => {
37 expect(ReactNoop.getChildrenAsJSX()).toEqual(expectedJSX);
38 });
39 }
40 return JestReact.unstable_toMatchRenderedOutput(ReactNoop, expectedJSX);
41}
42
43module.exports = {
44 ...SchedulerMatchers,

Callers

nothing calls this directly

Calls 2

assertYieldsWereClearedFunction · 0.70
captureAssertionFunction · 0.70

Tested by

no test coverage detected