Index: tests/language_strong/malformed_test.dart |
diff --git a/tests/language_strong/malformed_test.dart b/tests/language_strong/malformed_test.dart |
index 22851bf3f015f148963caf81add046a3192d3ff2..23ba383ef5802c2cee17df359580ff2e8283e3aa 100644 |
--- a/tests/language_strong/malformed_test.dart |
+++ b/tests/language_strong/malformed_test.dart |
@@ -6,7 +6,7 @@ |
// wrong number of type arguments are handled as raw types. |
import 'package:expect/expect.dart'; |
-import 'package:expect/expect.dart' as prefix; // Define 'prefix'. |
+import 'package:expect/expect.dart' as prefix; // Define 'prefix'. |
checkIsUnresolved(var v) { |
Expect.throws(() => v is Unresolved, (e) => e is TypeError); |
@@ -46,8 +46,8 @@ checkAsListUnresolved(bool expect, var v) { |
Expect.throws(() => v as List<Unresolved>, (e) => e is CastError); |
Expect.throws(() => v as List<Unresolved<int>>, (e) => e is CastError); |
Expect.throws(() => v as List<prefix.Unresolved>, (e) => e is CastError); |
- Expect.throws( |
- () => v as List<prefix.Unresolved<int>>, (e) => e is CastError); |
+ Expect.throws(() => v as List<prefix.Unresolved<int>>, |
+ (e) => e is CastError); |
Expect.throws(() => v as List<int, String>, (e) => e is CastError); |
} |
} |
@@ -57,6 +57,7 @@ checkIsMapDynamic(bool first, bool second, var v) { |
Expect.equals(second, v is Map<Object, int> && v is Map<Object, String>); |
} |
+ |
void main() { |
checkIsUnresolved(''); |
checkIsUnresolved(0); |
@@ -99,7 +100,7 @@ void main() { |
checkIsMapDynamic(true, true, <String, int, String>{}); |
checkIsMapDynamic(true, false, <Unresolved, int>{}); |
checkIsMapDynamic(false, true, <String, Unresolved<int>>{}); |
- checkIsMapDynamic(true, false, <prefix.Unresolved, int>{}); |
+ checkIsMapDynamic(true, false, <prefix.Unresolved, int>{}); |
checkIsMapDynamic(false, true, <String, prefix.Unresolved<int>>{}); |
checkIsMapDynamic(true, true, new Map()); |
@@ -109,7 +110,7 @@ void main() { |
checkIsMapDynamic(true, true, new Map<String, int, String>()); |
checkIsMapDynamic(true, false, new Map<Unresolved, int>()); |
checkIsMapDynamic(false, true, new Map<String, Unresolved<int>>()); |
- checkIsMapDynamic(true, false, new Map<prefix.Unresolved, int>()); |
+ checkIsMapDynamic(true, false, new Map<prefix.Unresolved, int>()); |
checkIsMapDynamic(false, true, new Map<String, prefix.Unresolved<int>>()); |
Expect.throws(() => new Unresolved(), (e) => true); |
@@ -130,7 +131,8 @@ void main() { |
Expect.fail("This code shouldn't be executed"); |
} |
Expect.fail("This code shouldn't be executed"); |
- } on TypeError catch (e) {} |
+ } on TypeError catch (e) { |
+ } |
try { |
try { |
throw 'foo'; |
@@ -138,7 +140,8 @@ void main() { |
Expect.fail("This code shouldn't be executed"); |
} |
Expect.fail("This code shouldn't be executed"); |
- } on TypeError catch (e) {} |
+ } on TypeError catch (e) { |
+ } |
try { |
try { |
throw 'foo'; |
@@ -146,7 +149,8 @@ void main() { |
Expect.fail("This code shouldn't be executed"); |
} |
Expect.fail("This code shouldn't be executed"); |
- } on TypeError catch (e) {} |
+ } on TypeError catch (e) { |
+ } |
try { |
try { |
throw 'foo'; |
@@ -154,10 +158,12 @@ void main() { |
Expect.fail("This code shouldn't be executed"); |
} |
Expect.fail("This code shouldn't be executed"); |
- } on TypeError catch (e) {} |
+ } on TypeError catch (e) { |
+ } |
try { |
throw 'foo'; |
} |
on undeclared_prefix.Unresolved<int> // //# 06: runtime error |
- catch (e) {} |
-} |
+ catch (e) { |
+ } |
+} |