blob: 69ad3b953fe5c75825209f1bf0919877c28a616e [file] [log] [blame]
# Copyright (c) 2021, 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.md file.
# Reproduction of https://github.com/dart-lang/sdk/issues/47176
# Compile an application with modules where one module has imported another
# module with too many slashes. Now try to import it correctly.
# This is essentially equivalent to not loading a needed component.
type: newworld
target: DDC
modules:
moduleA:
moduleA/x/lib.dart: |
void foo() { }
moduleA/.packages: |
moduleA:.
moduleB:
moduleB/x/lib.dart: |
// Mind the double-slash! (on Windows this could probably also be a change
// in case (e.g 'lib' vs 'Lib')).
import 'package:moduleA/x//lib.dart';
void bar() { }
moduleB/.packages: |
moduleA:../moduleA
moduleB:.
worlds:
- entry: main.dart
fromComponent: true
sources:
main.dart: |
import 'package:moduleB/x/lib.dart';
main() {
bar();
}
.packages: |
moduleA:moduleA
moduleB:moduleB
modules:
- moduleA
- moduleB
expectedLibraryCount: 3
neededDillLibraries:
- package:module/x/lib.dart
expectedContent:
org-dartlang-test:///main.dart:
- Procedure main
package:module/lib.dart:
- Procedure foo