a5b890f90d
This enables sharing (by duplicating) the common code not included into the host app between dynamic modules. Bug: b/475757441 Change-Id: I4831fc8b996303691ea2311019d1957f52c7d40c Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/478370 Reviewed-by: Alexander Markov <alexmarkov@google.com> Commit-Queue: Ivan Inozemtsev <iinozemtsev@google.com>
19 lines
713 B
Dart
19 lines
713 B
Dart
// Copyright (c) 2026, the Dart project authors. Please see the AUTHORS file
|
|
// for details. All rights reserved. Use of this source code is governed by a
|
|
// BSD-style license that can be found in the LICENSE file.
|
|
import 'package:dart2bytecode/dart2bytecode.dart' show prefixUri;
|
|
import 'package:test/test.dart';
|
|
|
|
void main() {
|
|
group('prefixUri', () {
|
|
test('prefixes file URIs', () {
|
|
expect(prefixUri(Uri.parse('file:///foo/bar.dart'), ['pre', 'fix']),
|
|
Uri.parse('file:///pre/fix/foo/bar.dart'));
|
|
});
|
|
test('prefixes package URIs', () {
|
|
expect(prefixUri(Uri.parse('package:foo/bar.dart'), ['pre', 'fix']),
|
|
Uri.parse('package:pre.fix.foo/bar.dart'));
|
|
});
|
|
});
|
|
}
|