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

Unified Diff: tests/corelib_2/string_test.dart

Issue 2983253002: Migrated test block 29 to Dart 2.0 (Closed)
Patch Set: Migrated test block 29 to Dart 2.0 Created 3 years, 5 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_2/string_test.dart
diff --git a/tests/corelib_strong/string_test.dart b/tests/corelib_2/string_test.dart
similarity index 97%
rename from tests/corelib_strong/string_test.dart
rename to tests/corelib_2/string_test.dart
index d51d88df59637c3d9200e5c27f4348d03eaaf236..f66f16b672d809be0c9b2820c0319e56c03575a6 100644
--- a/tests/corelib_strong/string_test.dart
+++ b/tests/corelib_2/string_test.dart
@@ -6,7 +6,6 @@ import "package:expect/expect.dart";
void main() {
testOutOfRange();
- testIllegalArgument();
testConcat();
testIndex();
testCodeUnitAt();
@@ -43,21 +42,6 @@ void testOutOfRange() {
Expect.isTrue(exception_caught);
}
-void testIllegalArgument() {
- String a = "Hello";
- bool exception_caught = false;
- try {
- var c = a[2.2]; // Throw exception.
- Expect.fail("Accepting double as index");
- } on ArgumentError catch (e) {
- exception_caught = true;
- } on TypeError catch (e) {
- // Thrown in checked mode only.
- exception_caught = true;
- }
- Expect.isTrue(exception_caught);
-}
-
void testIndex() {
String str = "string";
for (int i = 0; i < str.length; i++) {

Powered by Google App Engine
This is Rietveld 408576698