Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

#2846. Add unquoted imports tests for path separator #2889

Merged
merged 4 commits into from
Sep 25, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions LanguageFeatures/Unquoted-imports/pubspec.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -8,5 +8,7 @@ environment:
sdk: '>=3.6.0-255.0.dev'

dependencies:
test.package1:
path: ./test.package1
test_package2:
path: ./test_package2
11 changes: 11 additions & 0 deletions LanguageFeatures/Unquoted-imports/test.package1/dummy.dart
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
// Copyright (c) 2024, 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.

/// @description Library file for testing unquoted imports. Must be unavailable
/// via `import 'package:...'` and its unquoted shortcut.
/// @author sgrekhov22@gmail.com

// SharedOptions=--enable-experiment=unquoted-imports

String libraryId = "Should not be used!";
8 changes: 8 additions & 0 deletions LanguageFeatures/Unquoted-imports/test.package1/lib/a/b.dart
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
// Copyright (c) 2024, 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.

/// @description Library file for testing unquoted imports.
/// @author sgrekhov22@gmail.com

String libraryId = "b1";
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
// Copyright (c) 2024, 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.

/// @description Library file for testing unquoted imports.
/// @author sgrekhov22@gmail.com

String libraryId = "c.d1";
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
// Copyright (c) 2024, 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.

/// @description Library file for testing unquoted imports.
/// @author sgrekhov22@gmail.com

String libraryId = "c1";
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
// Copyright (c) 2024, 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.

/// @description Library file for testing unquoted imports.
/// @author sgrekhov22@gmail.com

// SharedOptions=--enable-experiment=unquoted-imports

String libraryId = "dotted.name1";

String dottedName1 = "dotted.name1";
10 changes: 10 additions & 0 deletions LanguageFeatures/Unquoted-imports/test.package1/lib/package1.dart
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
// Copyright (c) 2024, 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.

/// @description Library file for testing unquoted imports.
/// @author sgrekhov22@gmail.com

// SharedOptions=--enable-experiment=unquoted-imports

String libraryId = "package1";
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
// Copyright (c) 2024, 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.

/// @description Library file for testing unquoted imports.
/// @author sgrekhov22@gmail.com

// SharedOptions=--enable-experiment=unquoted-imports

String libraryId = "test.package1";
8 changes: 8 additions & 0 deletions LanguageFeatures/Unquoted-imports/test.package1/pubspec.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
name: test.package1
description: Internal package used by co19 tests for Unquoted imports feature

# This tests isn't intended for publishing on pub.dev.
publish_to: none

environment:
sdk: '>=3.6.0-255.0.dev'
11 changes: 11 additions & 0 deletions LanguageFeatures/Unquoted-imports/test_package2/dummy.dart
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
// Copyright (c) 2024, 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.

/// @description Library file for testing unquoted imports. Must be unavailable
/// via `import 'package:...'` and its unquoted shortcut.
/// @author sgrekhov22@gmail.com

// SharedOptions=--enable-experiment=unquoted-imports

String libraryId = "Should not be used!";
8 changes: 8 additions & 0 deletions LanguageFeatures/Unquoted-imports/test_package2/lib/a/b.dart
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
// Copyright (c) 2024, 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.

/// @description Library file for testing unquoted imports.
/// @author sgrekhov22@gmail.com

String libraryId = "b2";
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
// Copyright (c) 2024, 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.

/// @description Library file for testing unquoted imports.
/// @author sgrekhov22@gmail.com

String libraryId = "c.d2";
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
// Copyright (c) 2024, 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.

/// @description Library file for testing unquoted imports.
/// @author sgrekhov22@gmail.com

String libraryId = "c2";
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
// Copyright (c) 2024, 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.

/// @description Library file for testing unquoted imports.
/// @author sgrekhov22@gmail.com

// SharedOptions=--enable-experiment=unquoted-imports

String libraryId = "dotted.name2";
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
// Copyright (c) 2024, 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.

/// @description Library file for testing unquoted imports.
/// @author sgrekhov22@gmail.com

// SharedOptions=--enable-experiment=unquoted-imports

String libraryId = "test_package2";

String testPackage2 = "test_package2";