| OLD | NEW |
| 1 // Copyright (c) 2013, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2013, the Dart project authors. Please see the AUTHORS file |
| 2 // for details. All rights reserved. Use of this source code is governed by a | 2 // for details. All rights reserved. Use of this source code is governed by a |
| 3 // BSD-style license that can be found in the LICENSE file. | 3 // BSD-style license that can be found in the LICENSE file. |
| 4 | 4 |
| 5 import 'package:scheduled_test/scheduled_test.dart'; | 5 import 'package:scheduled_test/scheduled_test.dart'; |
| 6 | 6 |
| 7 import 'package:metatest/metatest.dart'; | |
| 8 import '../utils.dart'; | 7 import '../utils.dart'; |
| 9 | 8 |
| 10 void main() { | 9 void main() { |
| 11 setUpMockClock(); | 10 setUpMockClock(); |
| 12 | 11 |
| 13 expectTestPasses("nested schedule() runs its function immediately (but " | 12 expectTestPasses("nested schedule() runs its function immediately (but " |
| 14 "asynchronously)", () { | 13 "asynchronously)", () { |
| 15 schedule(() { | 14 schedule(() { |
| 16 var nestedScheduleRun = false; | 15 var nestedScheduleRun = false; |
| 17 schedule(() { | 16 schedule(() { |
| (...skipping 49 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 67 "expect(..., completes) should report exceptions once", () { | 66 "expect(..., completes) should report exceptions once", () { |
| 68 schedule(() { | 67 schedule(() { |
| 69 expect(schedule(() { | 68 expect(schedule(() { |
| 70 throw 'error'; | 69 throw 'error'; |
| 71 }), completes); | 70 }), completes); |
| 72 | 71 |
| 73 return pumpEventQueue(); | 72 return pumpEventQueue(); |
| 74 }); | 73 }); |
| 75 }, (error) => expect(error, equals('error'))); | 74 }, (error) => expect(error, equals('error'))); |
| 76 } | 75 } |
| OLD | NEW |