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

Side by Side Diff: tests/corelib/collection_removes_test.dart

Issue 12212016: Remove Expect from core library. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 7 years, 10 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 4
5 import "package:expect/expect.dart";
6
5 testRemove(Collection base) { 7 testRemove(Collection base) {
6 int length = base.length; 8 int length = base.length;
7 for (int i = 0; i < length; i++) { 9 for (int i = 0; i < length; i++) {
8 Expect.isFalse(base.isEmpty); 10 Expect.isFalse(base.isEmpty);
9 base.remove(base.first); 11 base.remove(base.first);
10 } 12 }
11 Expect.isTrue(base.isEmpty); 13 Expect.isTrue(base.isEmpty);
12 } 14 }
13 15
14 testRemoveAll(Collection base, Iterable removes) { 16 testRemoveAll(Collection base, Iterable removes) {
(...skipping 85 matching lines...) Expand 10 before | Expand all | Expand 10 after
100 testRemoveAll(base.toSet(), delta); 102 testRemoveAll(base.toSet(), delta);
101 testRemoveAll(base.toSet(), deltaSet); 103 testRemoveAll(base.toSet(), deltaSet);
102 testRetainAll(base.toSet(), delta); 104 testRetainAll(base.toSet(), delta);
103 testRetainAll(base.toSet(), deltaSet); 105 testRetainAll(base.toSet(), deltaSet);
104 testRemoveMatching(base.toSet(), deltaSet.contains); 106 testRemoveMatching(base.toSet(), deltaSet.contains);
105 testRetainMatching(base.toSet(), (e) => !deltaSet.contains(e)); 107 testRetainMatching(base.toSet(), (e) => !deltaSet.contains(e));
106 } 108 }
107 } 109 }
108 } 110 }
109 111
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698