[squeak-dev] The Trunk: ToolBuilder-SUnit-cmm.15.mcz

commits at source.squeak.org commits at source.squeak.org
Wed Oct 19 03:02:32 UTC 2011


Chris Muller uploaded a new version of ToolBuilder-SUnit to project The Trunk:
http://source.squeak.org/trunk/ToolBuilder-SUnit-cmm.15.mcz

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

Name: ToolBuilder-SUnit-cmm.15
Author: cmm
Time: 18 October 2011, 8:13:48.61 pm
UUID: f798f016-1576-4829-b6b8-59573eb884ba
Ancestors: ToolBuilder-SUnit-nice.14

Added test for handling Notification inside a progress block.

=============== Diff against ToolBuilder-SUnit-nice.14 ===============

Item was added:
+ ----- Method: SUnitToolBuilderTests>>testHandlingNotification (in category 'tests') -----
+ testHandlingNotification
+ 	| receivedSignal resumed |
+ 	receivedSignal := resumed := false.
+ 	[ | count |
+ 	"client-code puts up progress, and signals some notications"
+ 	count := 0.
+ 	'doing something'
+ 		displayProgressFrom: 0
+ 		to: 10
+ 		during:
+ 			[ : bar | 10 timesRepeat:
+ 				[ bar value: (count := count + 1).
+ 				(Delay forMilliseconds: 200) wait.
+ 				Notification signal: 'message'.
+ 				resumed := true ] ] ]
+ 		on: Notification
+ 		do:
+ 			[ : noti | receivedSignal := true.
+ 			noti resume ].
+ 	self
+ 		 assert: receivedSignal ;
+ 		 assert: resumed!




More information about the Squeak-dev mailing list