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

Unified Diff: pkg/analyzer/test/dart/element/element_test.dart

Issue 1529923003: Moved the tests for the element model into locations corresponding to the implementation (Closed) Base URL: https://github.com/dart-lang/sdk.git@master
Patch Set: Created 5 years 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
Index: pkg/analyzer/test/dart/element/element_test.dart
diff --git a/pkg/analyzer/test/dart/element/element_test.dart b/pkg/analyzer/test/dart/element/element_test.dart
new file mode 100644
index 0000000000000000000000000000000000000000..ba6d5d12a8c9b8b823661628aea2e803385010e8
--- /dev/null
+++ b/pkg/analyzer/test/dart/element/element_test.dart
@@ -0,0 +1,30 @@
+// Copyright (c) 2014, 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.
+
+library analyzer.test.dart.element.element_test;
+
+import 'package:analyzer/dart/element/element.dart';
+import 'package:analyzer/src/generated/testing/element_factory.dart';
+import 'package:unittest/unittest.dart';
+
+import '../../generated/test_support.dart';
+import '../../reflective_tests.dart';
+import '../../utils.dart';
+
+main() {
+ initializeTestEnvironment();
+ runReflectiveTests(ElementKindTest);
+}
+
+@reflectiveTest
+class ElementKindTest extends EngineTestCase {
+ void test_of_nonNull() {
+ expect(ElementKind.of(ElementFactory.classElement2("A")),
+ same(ElementKind.CLASS));
+ }
+
+ void test_of_null() {
+ expect(ElementKind.of(null), same(ElementKind.ERROR));
+ }
+}
« no previous file with comments | « no previous file | pkg/analyzer/test/dart/element/test_all.dart » ('j') | pkg/analyzer/test/dart/element/test_all.dart » ('J')

Powered by Google App Engine
This is Rietveld 408576698