Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(194)

Unified Diff: test/initializer_parts_test.dart

Issue 1018643002: change to source-order crawling of directives instead of alphabetical (Closed) Base URL: git@github.com:dart-lang/static-init.git@master
Patch Set: switch to bug fix instead of breaking change, and use definingCompilationUnit Created 5 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « test/foo/bar.dart ('k') | test/initializer_test.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: test/initializer_parts_test.dart
diff --git a/test/initializer_parts_test.dart b/test/initializer_parts_test.dart
new file mode 100644
index 0000000000000000000000000000000000000000..bfba5e80df3cf469517b228f6db51e45c648f5f0
--- /dev/null
+++ b/test/initializer_parts_test.dart
@@ -0,0 +1,41 @@
+// Copyright (c) 2015, 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.
+@initializeTracker
+library initialize.initializer_parts_test;
+
+import 'package:initialize/src/initialize_tracker.dart';
+import 'package:initialize/initialize.dart';
+import 'package:unittest/unittest.dart';
+import 'package:unittest/compact_vm_config.dart';
+
+part 'parts/foo.dart';
+part 'parts/bar.dart';
+
+main() {
+ useCompactVMConfiguration();
+
+ // Run all initializers.
+ run().then((_) {
+ test('parts', () {
+ var expectedNames = [
+ const LibraryIdentifier(#initialize.initializer_parts_test, null, 'initializer_parts_test.dart'),
+ bar2,
+ bar,
+ foo,
+ baz,
+ Bar2,
+ Bar,
+ Foo,
+ Baz,
+ ];
+ expect(InitializeTracker.seen, expectedNames);
+ });
+ });
+}
+
+@initializeTracker
+class Baz {}
+
+@initializeTracker
+baz() {}
« no previous file with comments | « test/foo/bar.dart ('k') | test/initializer_test.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698