diff --git a/source_gen/test/builder_test.dart b/source_gen/test/builder_test.dart index 75efcf42..3eb2c439 100644 --- a/source_gen/test/builder_test.dart +++ b/source_gen/test/builder_test.dart @@ -265,14 +265,14 @@ class _LiteralGenerator extends Generator { const _LiteralGenerator([this._content]); @override - FutureOr generate(_, __) => _content; + String generate(_, __) => _content; } class _BadOutputGenerator extends Generator { const _BadOutputGenerator(); @override - Future generate(LibraryReader library, _) async => 'not valid code!'; + String generate(_, __) => 'not valid code!'; } final _customHeader = '// Copyright 1979'; diff --git a/source_gen/test/src/unformatted_code_generator.dart b/source_gen/test/src/unformatted_code_generator.dart index 8dd122a1..52ec3209 100644 --- a/source_gen/test/src/unformatted_code_generator.dart +++ b/source_gen/test/src/unformatted_code_generator.dart @@ -2,8 +2,6 @@ // for details. All rights reserved. Use of this source code is governed by a // BSD-style license that can be found in the LICENSE file. -import 'dart:async'; - import 'package:source_gen/source_gen.dart'; /// Generates a single-line of unformatted code. @@ -11,7 +9,7 @@ class UnformattedCodeGenerator extends Generator { const UnformattedCodeGenerator(); @override - Future generate(LibraryReader library, _) async => unformattedCode; + String generate(_, __) => unformattedCode; static const formattedCode = ''' void hello() => print('hello');