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

Unified Diff: tests/corelib_2/iterable_generate_test.dart

Issue 3000543002: Migrate test block 11 to Dart 2.0. (Closed)
Patch Set: Fix merge problems and update test status with head changes Created 3 years, 4 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 | « tests/corelib_2/corelib_2.status ('k') | tests/corelib_2/iterable_join_test.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tests/corelib_2/iterable_generate_test.dart
diff --git a/tests/corelib/iterable_generate_test.dart b/tests/corelib_2/iterable_generate_test.dart
similarity index 80%
rename from tests/corelib/iterable_generate_test.dart
rename to tests/corelib_2/iterable_generate_test.dart
index 4c2a9d58aa736104af0ba387dd4a3642c9219875..201c2e42209275aaef1a346c4b451473002b40a6 100644
--- a/tests/corelib/iterable_generate_test.dart
+++ b/tests/corelib_2/iterable_generate_test.dart
@@ -37,9 +37,7 @@ main() {
Expect.isFalse(st.iterator is Iterator<int>);
test(["0", "1", "2", "3", "4"], st);
- if (typeAssertionsEnabled) {
- Expect.throws(() => new Iterable<String>.generate(5));
- }
+ Expect.throws(() => new Iterable<String>.generate(5));
// Omitted generator function means `(int x) => x`, and the type parameters
// must then be compatible with `int`.
@@ -57,12 +55,7 @@ main() {
// Invalid types:
Expect.throws(() => new Iterable<String>.generate(5));
- if (typeAssertionsEnabled) { // //# 01: ok
- Expect.throws(() => new Iterable<Null>.generate(5).elementAt(2)); //# 01: continued
- } else { // //# 01: continued
- Iterable<dynamic> iter5 = new Iterable<Null>.generate(5); // //# 01: continued
- Expect.equals(2, iter5.elementAt(2)); // //# 01: continued
- } // //# 01: continued
+ Expect.throws(() => new Iterable<Null>.generate(5).elementAt(2)); //# 01: ok
Expect.throws(() => new Iterable<bool>.generate(5));
// Regression: https://github.com/dart-lang/sdk/issues/26358
« no previous file with comments | « tests/corelib_2/corelib_2.status ('k') | tests/corelib_2/iterable_join_test.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698