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

Unified Diff: tests/corelib/string_codeunits_test.dart

Issue 12817003: Change getRange to sublist. Make getRange deprecated. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Addressed review comments 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 side-by-side diff with in-line comments
Download patch
Index: tests/corelib/string_codeunits_test.dart
diff --git a/tests/corelib/string_codeunits_test.dart b/tests/corelib/string_codeunits_test.dart
index ac6eb97c5cf0efa8cb9899f913573f679bd112fc..28b9df4edf612414893911aea54fdd5718bbd257 100644
--- a/tests/corelib/string_codeunits_test.dart
+++ b/tests/corelib/string_codeunits_test.dart
@@ -31,7 +31,7 @@ main() {
Expect.throws(() => units.last, (e) => e is StateError);
Expect.throws(() => units[0], (e) => e is RangeError);
Expect.throws(() => units[0] = 499, (e) => e is UnsupportedError);
- Expect.listEquals([], units.getRange(0, 0));
+ Expect.listEquals([], units.sublist(0, 0));
Expect.equals(-1, units.indexOf(42));
Expect.equals(-1, units.lastIndexOf(499));
} else {
@@ -39,7 +39,7 @@ main() {
Expect.equals(s.codeUnitAt(s.length - 1), units.last);
Expect.equals(s.codeUnitAt(0), units[0]);
Expect.throws(() { units[0] = 499; }, (e) => e is UnsupportedError);
- List<int> sub = units.getRange(1, units.length - 1);
+ List<int> sub = units.sublist(1);
Expect.listEquals(s.substring(1, s.length).codeUnits, sub);
Expect.equals(-1, units.indexOf(-1));
Expect.equals(0, units.indexOf(units[0]));

Powered by Google App Engine
This is Rietveld 408576698