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

Side by Side Diff: tests/compiler/dart2js/resolver_test.dart

Issue 70703002: Add constructors for JSArray (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 7 years, 1 month 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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « tests/compiler/dart2js/mock_compiler.dart ('k') | tests/compiler/dart2js/value_range_test.dart » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file
2 // for details. All rights reserved. Use of this source code is governed by a 2 // for details. All rights reserved. Use of this source code is governed by a
3 // BSD-style license that can be found in the LICENSE file. 3 // BSD-style license that can be found in the LICENSE file.
4 4
5 import "package:expect/expect.dart"; 5 import "package:expect/expect.dart";
6 import 'dart:async'; 6 import 'dart:async';
7 import "package:async_helper/async_helper.dart"; 7 import "package:async_helper/async_helper.dart";
8 import 'dart:collection'; 8 import 'dart:collection';
9 9
10 import "../../../sdk/lib/_internal/compiler/implementation/resolution/resolution .dart"; 10 import "../../../sdk/lib/_internal/compiler/implementation/resolution/resolution .dart";
(...skipping 793 matching lines...) Expand 10 before | Expand all | Expand 10 after
804 804
805 script = ""; 805 script = "";
806 final String CORELIB_WITH_INVALID_OBJECT = 806 final String CORELIB_WITH_INVALID_OBJECT =
807 '''print(var obj) {} 807 '''print(var obj) {}
808 class int {} 808 class int {}
809 class double {} 809 class double {}
810 class bool {} 810 class bool {}
811 class String {} 811 class String {}
812 class num {} 812 class num {}
813 class Function {} 813 class Function {}
814 class List {} 814 class List<E> {}
815 class Map {} 815 class Map {}
816 class Closure {} 816 class Closure {}
817 class Null {} 817 class Null {}
818 class StackTrace {} 818 class StackTrace {}
819 class Dynamic_ {} 819 class Dynamic_ {}
820 class Type {} 820 class Type {}
821 class Object { Object() : super(); }'''; 821 class Object { Object() : super(); }''';
822 resolveConstructor(script, "Object o = new Object();", "Object", "", 1, 822 resolveConstructor(script, "Object o = new Object();", "Object", "", 1,
823 expectedWarnings: [], 823 expectedWarnings: [],
824 expectedErrors: [MessageKind.SUPER_INITIALIZER_IN_OBJECT], 824 expectedErrors: [MessageKind.SUPER_INITIALIZER_IN_OBJECT],
(...skipping 140 matching lines...) Expand 10 before | Expand all | Expand 10 after
965 }"""; 965 }""";
966 asyncTest(() => compileScript(script2).then((compiler) { 966 asyncTest(() => compileScript(script2).then((compiler) {
967 expect(compiler, 967 expect(compiler,
968 [MessageKind.CONST_CONSTRUCTOR_WITH_NONFINAL_FIELDS], 968 [MessageKind.CONST_CONSTRUCTOR_WITH_NONFINAL_FIELDS],
969 [MessageKind.CONST_CONSTRUCTOR_WITH_NONFINAL_FIELDS_CONSTRUCTOR, 969 [MessageKind.CONST_CONSTRUCTOR_WITH_NONFINAL_FIELDS_CONSTRUCTOR,
970 MessageKind.CONST_CONSTRUCTOR_WITH_NONFINAL_FIELDS_CONSTRUCTOR, 970 MessageKind.CONST_CONSTRUCTOR_WITH_NONFINAL_FIELDS_CONSTRUCTOR,
971 MessageKind.CONST_CONSTRUCTOR_WITH_NONFINAL_FIELDS_FIELD, 971 MessageKind.CONST_CONSTRUCTOR_WITH_NONFINAL_FIELDS_FIELD,
972 MessageKind.CONST_CONSTRUCTOR_WITH_NONFINAL_FIELDS_FIELD]); 972 MessageKind.CONST_CONSTRUCTOR_WITH_NONFINAL_FIELDS_FIELD]);
973 })); 973 }));
974 } 974 }
OLDNEW
« no previous file with comments | « tests/compiler/dart2js/mock_compiler.dart ('k') | tests/compiler/dart2js/value_range_test.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698