[web] Ensure CanvasKit is served from the correct location (#121902)

[web] Ensure CanvasKit is served from the correct location
This commit is contained in:
Mouad Debbar
2023-03-07 16:38:35 -05:00
committed by GitHub
parent a626f4db6f
commit 95c2ad5047
3 changed files with 38 additions and 7 deletions

View File

@@ -145,6 +145,10 @@ void main() {
artifacts.getArtifactPath(Artifact.frontendServerSnapshotForEngineDartSdk),
fileSystem.path.join('root', 'bin', 'cache', 'dart-sdk', 'bin', 'snapshots', 'frontend_server.dart.snapshot')
);
expect(
artifacts.getArtifactPath(Artifact.canvasKitPath),
fileSystem.path.join('root', 'bin', 'cache', 'flutter_web_sdk', 'canvaskit'),
);
});
testWithoutContext('precompiled web artifact paths are correct', () {
@@ -342,6 +346,10 @@ void main() {
artifacts.getHostArtifact(HostArtifact.libtessellator).path,
fileSystem.path.join('/out', 'host_debug_unopt', 'libtessellator.so'),
);
expect(
artifacts.getArtifactPath(Artifact.canvasKitPath, platform: TargetPlatform.web_javascript),
fileSystem.path.join('/out', 'wasm_release', 'canvaskit'),
);
});
testWithoutContext('falls back to bundled impeller artifacts if the files do not exist in the local engine', () {