The Trunk: KernelTests-tonyg.333.mcz

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|

The Trunk: KernelTests-tonyg.333.mcz

commits-2
Tony Garnock-Jones uploaded a new version of KernelTests to project The Trunk:
http://source.squeak.org/trunk/KernelTests-tonyg.333.mcz

==================== Summary ====================

Name: KernelTests-tonyg.333
Author: tonyg
Time: 9 February 2018, 11:52:53.528808 am
UUID: 62b9b71c-3c04-49d0-8a85-9afb2e0adcb6
Ancestors: KernelTests-ul.332

Extend PromiseTest cases for waitTimeoutMSecs: to examine isRejected status.

=============== Diff against KernelTests-ul.332 ===============

Item was changed:
  ----- Method: PromiseTest>>testTimeout (in category 'testing') -----
  testTimeout
  | promise |
  promise := Promise new.
  self shouldnt: [promise waitTimeoutMSecs: 1].
  self shouldnt: [promise isResolved].
+ self shouldnt: [promise isRejected].
  promise resolveWith: 45.
  self should: [promise waitTimeoutMSecs: 1].
  self should: [promise isResolved].
+ self shouldnt: [promise isRejected].!
- !

Item was added:
+ ----- Method: PromiseTest>>testTimeoutRejected (in category 'testing') -----
+ testTimeoutRejected
+ | promise |
+ promise := Promise new.
+ self shouldnt: [promise waitTimeoutMSecs: 1].
+ self shouldnt: [promise isResolved].
+ self shouldnt: [promise isRejected].
+ promise rejectWith: 45.
+ self shouldnt: [promise waitTimeoutMSecs: 1].
+ self shouldnt: [promise isResolved].
+ self should: [promise isRejected].!