logsPropTypeWarnings function

_PropTypeLogMatcher logsPropTypeWarnings(
  1. dynamic expected
)

Matcher used to check for specific propType warnings being emitted during the runtime of a callback function.

Has the same underlying logic as logsToConsole, with the difference being that console configuration is set to errorConfig and non-propType related warnings are filtered out of the list.

In the case the actual value is a callback that is run, any errors caused by the callback will be caught. Because the console configuration is set to errorConfig, the actual list of logs will include the error message from the caught error.

Related: logsPropTypeWarning, logsNoPropTypeWarnings, logsToConsole

Implementation

_PropTypeLogMatcher logsPropTypeWarnings(dynamic expected) =>
    _PropTypeLogMatcher(expected);