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

Side by Side Diff: tests/language/super_operator_test.dart

Issue 12743005: Revert "Remove Expect from core library." (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Reupload (first upload failed). Created 7 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 unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2011, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2011, 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 // Dart test for testing super operator calls 4 // Dart test for testing super operator calls
5 5
6 import "package:expect/expect.dart";
7
8 6
9 class A { 7 class A {
10 String val = ""; 8 String val = "";
11 List things; 9 List things;
12 10
13 A() : things = ['D', 'a', 'r', 't', 42]; 11 A() : things = ['D', 'a', 'r', 't', 42];
14 12
15 operator + (String s) { 13 operator + (String s) {
16 val = "${val}${s}"; 14 val = "${val}${s}";
17 return this; 15 return this;
(...skipping 53 matching lines...) Expand 10 before | Expand all | Expand 10 after
71 a += "Tell"; // operator + of class B. 69 a += "Tell"; // operator + of class B.
72 Expect.equals("TellTell", a.val); 70 Expect.equals("TellTell", a.val);
73 Expect.equals("rr", a[2]); // operator [] of class B. 71 Expect.equals("rr", a[2]); // operator [] of class B.
74 72
75 a[4] = 1; // operator []= of class B. 73 a[4] = 1; // operator []= of class B.
76 Expect.equals(43, a.things[4]); 74 Expect.equals(43, a.things[4]);
77 Expect.equals(86, a[4]); 75 Expect.equals(86, a[4]);
78 76
79 Expect.throws(testRegression6403); 77 Expect.throws(testRegression6403);
80 } 78 }
OLDNEW
« no previous file with comments | « tests/language/super_operator_index6_test.dart ('k') | tests/language/super_setter_interceptor_test.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698