withEnabled method
Creates a WidgetSelector that finds all ElevatedButton where enabled equals (==) value
.
Example usage:
spot<ElevatedButton>().withEnabled(true).existsOnce();
Implementation
@useResult
WidgetSelector<ElevatedButton> withEnabled(bool? value) {
return withDiagnosticProp<bool>(
'enabled', (it) => value == null ? it.isNull() : it.equals(value));
}