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/list_iterators_test.dart

Issue 12040018: Make ListIterator throw if the underlying list's length changes. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 7 years, 11 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
« no previous file with comments | « sdk/lib/collection_dev/list.dart ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tests/corelib/list_iterators_test.dart
diff --git a/tests/corelib/list_iterators_test.dart b/tests/corelib/list_iterators_test.dart
index 66d2179f8451eba28a4b2051a18a8c63e48b60c5..c20e5ebe7d885be5cde542590f835a5b9e1c4959 100644
--- a/tests/corelib/list_iterators_test.dart
+++ b/tests/corelib/list_iterators_test.dart
@@ -37,6 +37,9 @@ class ListIteratorsTest {
g.removeLast();
// The iterator keeps the last value.
Expect.equals(3, it.current);
+ Expect.throws(it.moveNext, (e) => e is ConcurrentModificationError);
+ // No progress when throwing.
+ Expect.equals(3, it.current);
}
}
« no previous file with comments | « sdk/lib/collection_dev/list.dart ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698