hasLabel method

WidgetMatcher<Semantics> hasLabel(
  1. String? value
)

Expects that label of Semantics equals (==) value.

Example usage:

spot<Semantics>().existsOnce().hasLabel('foo');

Implementation

WidgetMatcher<Semantics> hasLabel(String? value) {
  return hasDiagnosticProp<String>(
      'label', (it) => value == null ? it.isNull() : it.equals(value));
}