Wire up hot restart and incremental rebuilds for web (#33197)
This commit is contained in:
@@ -12,7 +12,6 @@ void main() {
|
||||
test('no unauthorized imports of dart:io', () {
|
||||
final List<String> whitelistedPaths = <String>[
|
||||
fs.path.join(flutterTools, 'lib', 'src', 'base', 'io.dart'),
|
||||
fs.path.join(flutterTools, 'lib', 'src', 'build_runner', 'kernel_builder.dart'),
|
||||
];
|
||||
bool _isNotWhitelisted(FileSystemEntity entity) => whitelistedPaths.every((String path) => path != entity.path);
|
||||
|
||||
@@ -35,7 +34,7 @@ void main() {
|
||||
});
|
||||
|
||||
test('no unauthorized imports of package:path', () {
|
||||
final String whitelistedPath = fs.path.join(flutterTools, 'lib', 'src', 'build_runner', 'kernel_builder.dart');
|
||||
final String whitelistedPath = fs.path.join(flutterTools, 'lib', 'src', 'build_runner', 'web_compilation_delegate.dart');
|
||||
for (String dirName in <String>['lib', 'bin', 'test']) {
|
||||
final Iterable<File> files = fs.directory(fs.path.join(flutterTools, dirName))
|
||||
.listSync(recursive: true)
|
||||
@@ -57,7 +56,6 @@ void main() {
|
||||
test('no unauthorized imports of dart:convert', () {
|
||||
final List<String> whitelistedPaths = <String>[
|
||||
fs.path.join(flutterTools, 'lib', 'src', 'convert.dart'),
|
||||
fs.path.join(flutterTools, 'lib', 'src', 'build_runner', 'kernel_builder.dart'),
|
||||
];
|
||||
bool _isNotWhitelisted(FileSystemEntity entity) => whitelistedPaths.every((String path) => path != entity.path);
|
||||
|
||||
|
||||
@@ -30,7 +30,7 @@ void main() {
|
||||
});
|
||||
|
||||
test('invokes dart2js with correct arguments', () => testBed.run(() async {
|
||||
await webCompiler.compile(target: 'lib/main.dart');
|
||||
await webCompiler.compileDart2js(target: 'lib/main.dart');
|
||||
|
||||
verify(mockProcessManager.start(<String>[
|
||||
'bin/cache/dart-sdk/bin/dart',
|
||||
|
||||
@@ -21,7 +21,7 @@ void main() {
|
||||
|
||||
setUp(() async {
|
||||
flutterProject = FlutterProject.fromPath(fs.path.join(getFlutterRoot(), 'dev', 'integration_tests', 'web'));
|
||||
when(mockWebCompiler.compile(
|
||||
when(mockWebCompiler.compileDart2js(
|
||||
target: anyNamed('target'),
|
||||
minify: anyNamed('minify'),
|
||||
enabledAssertions: anyNamed('enabledAssertions'),
|
||||
|
||||
Reference in New Issue
Block a user