Unverified Commit fd6baba1 authored by Chris Bracken's avatar Chris Bracken Committed by GitHub

Allow spaces in SDK path in flutter_tools tests (#14617)

The Flutter engine now supports package: and file: imports that resolve
to paths on disk that include spaces and other URI-escaped characters.
This patch eliminates the restriction that Dart source paths not include
%20 (or other URI-escaped characters) in their paths in flutter_tool
tests.
parent cb53e4e5
...@@ -32,7 +32,7 @@ String getFlutterRoot() { ...@@ -32,7 +32,7 @@ String getFlutterRoot() {
scriptUri = platform.script; scriptUri = platform.script;
break; break;
case 'data': case 'data':
final RegExp flutterTools = new RegExp(r'(file://[^%]*[/\\]flutter_tools[^%]+\.dart)%'); final RegExp flutterTools = new RegExp(r'(file://[^ ;]*[/\\]flutter_tools[^%]+\.dart)%');
final Match match = flutterTools.firstMatch(platform.script.path); final Match match = flutterTools.firstMatch(platform.script.path);
if (match == null) if (match == null)
throw invalidScript(); throw invalidScript();
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment