shouldMatch method

void shouldMatch(
  1. dynamic regExp
)

Asserts that the value matches the regular expression given by regExp. regExp can be a RegExp instance or a String.

Implementation

void shouldMatch(dynamic regExp) {
  expect(
    this,
    matches(regExp),
    reason: 'Expected $this to match $regExp',
  );
}