withWidth method

  1. @useResult
WidgetSelector<SizedBox> withWidth(
  1. double? value
)

Creates a WidgetSelector that finds all SizedBox where width equals (==) value.

Example usage:

spot<SizedBox>().withWidth(10.5).existsOnce();

Implementation

@useResult
WidgetSelector<SizedBox> withWidth(double? value) {
  return withDiagnosticProp<double>(
      'width', (it) => value == null ? it.isNull() : it.equals(value));
}