[test] Fix URI parsing on Windows in incompatible_loading_unit_test.

The input is already a URI, not a path.

Bug: https://github.com/dart-lang/sdk/issues/41974
Change-Id: I6f2ba57867c75ddedff99c5723207bf5fe6d37d0
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/159180
Reviewed-by: Alexander Markov <alexmarkov@google.com>
Commit-Queue: Ryan Macnak <rmacnak@google.com>
diff --git a/runtime/tests/vm/dart/incompatible_loading_unit_test.dart b/runtime/tests/vm/dart/incompatible_loading_unit_test.dart
index 9adf6e8..73a7a6d 100644
--- a/runtime/tests/vm/dart/incompatible_loading_unit_test.dart
+++ b/runtime/tests/vm/dart/incompatible_loading_unit_test.dart
@@ -36,7 +36,7 @@
       var uris = <String>[];
       for (var uri in unit['libraries']) {
         if (uri.startsWith("dart:")) continue;
-        uris.add(Uri.file(uri).pathSegments.last);
+        uris.add(Uri.parse(uri).pathSegments.last);
       }
       uris.sort((a, b) => a.compareTo(b));
       units.add(uris);
diff --git a/runtime/tests/vm/dart_2/incompatible_loading_unit_test.dart b/runtime/tests/vm/dart_2/incompatible_loading_unit_test.dart
index 9adf6e8..73a7a6d 100644
--- a/runtime/tests/vm/dart_2/incompatible_loading_unit_test.dart
+++ b/runtime/tests/vm/dart_2/incompatible_loading_unit_test.dart
@@ -36,7 +36,7 @@
       var uris = <String>[];
       for (var uri in unit['libraries']) {
         if (uri.startsWith("dart:")) continue;
-        uris.add(Uri.file(uri).pathSegments.last);
+        uris.add(Uri.parse(uri).pathSegments.last);
       }
       uris.sort((a, b) => a.compareTo(b));
       units.add(uris);