diff --git a/packages/flutter_tools/lib/src/isolated/devfs_web.dart b/packages/flutter_tools/lib/src/isolated/devfs_web.dart index d19d8e20e72..3e1704da9f6 100644 --- a/packages/flutter_tools/lib/src/isolated/devfs_web.dart +++ b/packages/flutter_tools/lib/src/isolated/devfs_web.dart @@ -630,41 +630,43 @@ class WebAssetServer implements AssetReader { return webSdkFile; } + // TODO(yjbanov): https://github.com/flutter/flutter/issues/70121 static const Map> _dartSdkJsArtifactMap = > { WebRendererMode.autoDetect: { NullSafetyMode.sound: Artifact.webPrecompiledCanvaskitAndHtmlSoundSdk, NullSafetyMode.unsound: Artifact.webPrecompiledCanvaskitAndHtmlSdk, - NullSafetyMode.autodetect: Artifact.webPrecompiledCanvaskitAndHtmlSoundSdk, + NullSafetyMode.autodetect: Artifact.webPrecompiledCanvaskitAndHtmlSdk, }, WebRendererMode.canvaskit: { NullSafetyMode.sound: Artifact.webPrecompiledCanvaskitSoundSdk, NullSafetyMode.unsound: Artifact.webPrecompiledCanvaskitSdk, - NullSafetyMode.autodetect: Artifact.webPrecompiledCanvaskitSoundSdk, + NullSafetyMode.autodetect: Artifact.webPrecompiledCanvaskitSdk, }, WebRendererMode.html: { NullSafetyMode.sound: Artifact.webPrecompiledSoundSdk, NullSafetyMode.unsound: Artifact.webPrecompiledSdk, - NullSafetyMode.autodetect: Artifact.webPrecompiledSoundSdk, + NullSafetyMode.autodetect: Artifact.webPrecompiledSdk, }, }; + // TODO(yjbanov): https://github.com/flutter/flutter/issues/70121 static const Map> _dartSdkJsMapArtifactMap = > { WebRendererMode.autoDetect: { NullSafetyMode.sound: Artifact.webPrecompiledCanvaskitAndHtmlSoundSdkSourcemaps, NullSafetyMode.unsound: Artifact.webPrecompiledCanvaskitAndHtmlSdkSourcemaps, - NullSafetyMode.autodetect: Artifact.webPrecompiledCanvaskitAndHtmlSoundSdkSourcemaps, + NullSafetyMode.autodetect: Artifact.webPrecompiledCanvaskitAndHtmlSdkSourcemaps, }, WebRendererMode.canvaskit: { NullSafetyMode.sound: Artifact.webPrecompiledCanvaskitSoundSdkSourcemaps, NullSafetyMode.unsound: Artifact.webPrecompiledCanvaskitSdkSourcemaps, - NullSafetyMode.autodetect: Artifact.webPrecompiledCanvaskitSoundSdkSourcemaps, + NullSafetyMode.autodetect: Artifact.webPrecompiledCanvaskitSdkSourcemaps, }, WebRendererMode.html: { NullSafetyMode.sound: Artifact.webPrecompiledSoundSdkSourcemaps, NullSafetyMode.unsound: Artifact.webPrecompiledSdkSourcemaps, - NullSafetyMode.autodetect: Artifact.webPrecompiledSoundSdkSourcemaps, + NullSafetyMode.autodetect: Artifact.webPrecompiledSdkSourcemaps, }, }; diff --git a/packages/flutter_tools/test/general.shard/web/devfs_web_test.dart b/packages/flutter_tools/test/general.shard/web/devfs_web_test.dart index ed77f8381d6..3e156bb748f 100644 --- a/packages/flutter_tools/test/general.shard/web/devfs_web_test.dart +++ b/packages/flutter_tools/test/general.shard/web/devfs_web_test.dart @@ -756,24 +756,24 @@ void main() { .childFile('web_entrypoint.dart') ..createSync(recursive: true) ..writeAsStringSync('GENERATED'); - final String webPrecompiledSoundSdk = globals.artifacts - .getArtifactPath(Artifact.webPrecompiledSoundSdk); - final String webPrecompiledSoundSdkSourcemaps = globals.artifacts - .getArtifactPath(Artifact.webPrecompiledSoundSdkSourcemaps); - final String webPrecompiledCanvaskitSoundSdk = globals.artifacts - .getArtifactPath(Artifact.webPrecompiledCanvaskitSoundSdk); - final String webPrecompiledCanvaskitSoundSdkSourcemaps = globals.artifacts - .getArtifactPath(Artifact.webPrecompiledCanvaskitSoundSdkSourcemaps); - globals.fs.file(webPrecompiledSoundSdk) + final String webPrecompiledSdk = globals.artifacts + .getArtifactPath(Artifact.webPrecompiledSdk); + final String webPrecompiledSdkSourcemaps = globals.artifacts + .getArtifactPath(Artifact.webPrecompiledSdkSourcemaps); + final String webPrecompiledCanvaskitSdk = globals.artifacts + .getArtifactPath(Artifact.webPrecompiledCanvaskitSdk); + final String webPrecompiledCanvaskitSdkSourcemaps = globals.artifacts + .getArtifactPath(Artifact.webPrecompiledCanvaskitSdkSourcemaps); + globals.fs.file(webPrecompiledSdk) ..createSync(recursive: true) ..writeAsStringSync('HELLO'); - globals.fs.file(webPrecompiledSoundSdkSourcemaps) + globals.fs.file(webPrecompiledSdkSourcemaps) ..createSync(recursive: true) ..writeAsStringSync('THERE'); - globals.fs.file(webPrecompiledCanvaskitSoundSdk) + globals.fs.file(webPrecompiledCanvaskitSdk) ..createSync(recursive: true) ..writeAsStringSync('OL'); - globals.fs.file(webPrecompiledCanvaskitSoundSdkSourcemaps) + globals.fs.file(webPrecompiledCanvaskitSdkSourcemaps) ..createSync(recursive: true) ..writeAsStringSync('CHUM'); @@ -798,7 +798,7 @@ void main() { expect(await webDevFS.webAssetServer.dartSourceContents('dart_sdk.js.map'), 'THERE'); // Update to the SDK. - globals.fs.file(webPrecompiledSoundSdk).writeAsStringSync('BELLOW'); + globals.fs.file(webPrecompiledSdk).writeAsStringSync('BELLOW'); // New SDK should be visible.. expect(await webDevFS.webAssetServer.dartSourceContents('dart_sdk.js'), 'BELLOW');