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

Unified Diff: tests/language/invocation_mirror_test.dart

Issue 11366152: Update language/invocation_mirror_test. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 8 years, 1 month 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 | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tests/language/invocation_mirror_test.dart
diff --git a/tests/language/invocation_mirror_test.dart b/tests/language/invocation_mirror_test.dart
index 38e12771eecce3134193c52c4d69af4c95a9189d..765fe08f3ff9c029916a39b9750df56baa7fdc1d 100644
--- a/tests/language/invocation_mirror_test.dart
+++ b/tests/language/invocation_mirror_test.dart
@@ -84,15 +84,11 @@ testInvocationMirrors() {
testInvocationMirror(n.bar(42), 'bar', [42], {});
testInvocationMirror(n.bar(x: 42), 'bar', [], {"x": 42});
testInvocationMirror(n.bar(37, x: 42), 'bar', [37], {"x": 42});
- testInvocationMirror((n.bar)(), 'bar', [], {});
- testInvocationMirror((n.bar)(42), 'bar', [42]);
- testInvocationMirror((n.bar)(x: 42), 'bar', [], {"x": 42});
- testInvocationMirror((n.bar)(37, x: 42), 'bar', [37], {"x": 42});
// Missing operator access.
testInvocationMirror(n + 4, '+', [4], {});
testInvocationMirror(n - 4, '-', [4], {});
- testInvocationMirror(-n, '-', [], {});
+ testInvocationMirror(-n, 'unary-', [], {});
testInvocationMirror(n[42], '[]', [42], {});
testInvocationMirror((n..[37] = 42).last, '[]=', [37, 42], {});
@@ -152,17 +148,22 @@ testNoSuchMethodErrors() {
test(Function block) {
Expect.throws(block, (e) => e is NoSuchMethodError);
}
-
+ var n = new N();
var o = new Object();
test(() => o.bar);
test(() => o.bar = 42);
test(() => o.bar());
+ test(() => o + 2);
+ test(() => -o);
+ test(() => o[0]);
+ test(() => o[0] = 42);
+ test(() => o());
test(() => o.toString = 42);
test(() => o.toString(42));
test(() => o.toString(x: 37));
test(() => o.hashCode = 42);
test(() => o.hashCode()); // Thrown by int.noSuchMethod.
- test(() => o());
+ test(n.flif); // Extracted method has no noSuchMethod.
}
main() {
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698