generateWidgetDriver function
Builder
generateWidgetDriver(
- BuilderOptions options
source_gen helper function, which calls WidgetDriverGenerator to generate TestDrivers and WidgetDriverProviders
Implementation
Builder generateWidgetDriver(BuilderOptions options) {
final customLineLength = options.config['lineLength'];
if (customLineLength != null && customLineLength is! int) {
throw Exception("lineLength specified in build.yaml that is not of type int");
}
return SharedPartBuilder(
[WidgetDriverGenerator(options: options)],
'widget_driver_generator',
formatOutput: DartFormatter(pageWidth: customLineLength).format,
);
}