Index: tests/lib/async/zone_register_callback_unary_test.dart |
diff --git a/tests/lib/async/zone_register_callback_unary_test.dart b/tests/lib/async/zone_register_callback_unary_test.dart |
index 2049e0264420ca241005b4adc4c053cfacc67ff1..67697fe0da76a828d7b5ce5b061a2f84bbbc3b6e 100644 |
--- a/tests/lib/async/zone_register_callback_unary_test.dart |
+++ b/tests/lib/async/zone_register_callback_unary_test.dart |
@@ -14,17 +14,18 @@ main() { |
Expect.identical(Zone.ROOT, Zone.current); |
Zone forked = Zone.current.fork(specification: new ZoneSpecification( |
- registerUnaryCallback: (Zone self, ZoneDelegate parent, Zone origin, f(arg)) { |
- // The zone is still the same as when origin.run was invoked, which |
- // is the root zone. (The origin zone hasn't been set yet). |
- Expect.identical(Zone.current, Zone.ROOT); |
- // Note that not forwarding is completely legal, though not encouraged. |
- var capturedValue = valueToCapture; |
- return parent.registerUnaryCallback(origin, (arg) { |
- restoredValue = capturedValue; |
- return f(arg); |
- }); |
- })); |
+ registerUnaryCallback: |
+ (Zone self, ZoneDelegate parent, Zone origin, f(arg)) { |
+ // The zone is still the same as when origin.run was invoked, which |
+ // is the root zone. (The origin zone hasn't been set yet). |
+ Expect.identical(Zone.current, Zone.ROOT); |
+ // Note that not forwarding is completely legal, though not encouraged. |
+ var capturedValue = valueToCapture; |
+ return parent.registerUnaryCallback(origin, (arg) { |
+ restoredValue = capturedValue; |
+ return f(arg); |
+ }); |
+ })); |
valueToCapture = 499; |
var fun = (x) => x + 99; |
@@ -36,4 +37,4 @@ main() { |
var result = registered(399); |
Expect.equals(498, result); |
Expect.equals(499, restoredValue); |
-} |
+} |