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

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

Issue 12212016: Remove Expect from core library. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Add deprecation comment for ExpectException and revert one test. Created 7 years, 8 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
« no previous file with comments | « tests/corelib/string_fromcharcode_test.dart ('k') | tests/corelib/string_replace_all_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) 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 String.allMatches. 4 // Dart test for testing String.allMatches.
5 5
6 import "package:expect/expect.dart";
7
6 String str = "this is a string with hello here and hello there"; 8 String str = "this is a string with hello here and hello there";
7 9
8 main() { 10 main() {
9 testNoMatch(); 11 testNoMatch();
10 testOneMatch(); 12 testOneMatch();
11 testTwoMatches(); 13 testTwoMatches();
12 testEmptyPattern(); 14 testEmptyPattern();
13 testEmptyString(); 15 testEmptyString();
14 testEmptyPatternAndString(); 16 testEmptyPatternAndString();
15 } 17 }
(...skipping 52 matching lines...) Expand 10 before | Expand all | Expand 10 after
68 Iterable<Match> matches = pattern.allMatches(str); 70 Iterable<Match> matches = pattern.allMatches(str);
69 Expect.isFalse(matches.iterator.moveNext()); 71 Expect.isFalse(matches.iterator.moveNext());
70 } 72 }
71 73
72 testEmptyPatternAndString() { 74 testEmptyPatternAndString() {
73 String pattern = ""; 75 String pattern = "";
74 String str = ""; 76 String str = "";
75 Iterable<Match> matches = pattern.allMatches(str); 77 Iterable<Match> matches = pattern.allMatches(str);
76 Expect.isTrue(matches.iterator.moveNext()); 78 Expect.isTrue(matches.iterator.moveNext());
77 } 79 }
OLDNEW
« no previous file with comments | « tests/corelib/string_fromcharcode_test.dart ('k') | tests/corelib/string_replace_all_test.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698