[squeak-dev] The Trunk: Tests-ar.54.mcz

commits at source.squeak.org commits at source.squeak.org
Thu Mar 4 05:40:43 UTC 2010


Andreas Raab uploaded a new version of Tests to project The Trunk:
http://source.squeak.org/trunk/Tests-ar.54.mcz

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

Name: Tests-ar.54
Author: ar
Time: 3 March 2010, 9:40:26.558 pm
UUID: 641315e3-0990-a04c-8e7a-2374969f846e
Ancestors: Tests-ar.53

Add a test for the issue of terminating a well-behaved unwind block int he middle.

=============== Diff against Tests-ar.53 ===============

Item was added:
+ ----- Method: ProcessTerminateBug>>testTerminationDuringUnwind (in category 'tests') -----
+ testTerminationDuringUnwind
+ 	"An illustration of the issue of process termination during unwind.
+ 	This uses a well-behaved unwind block that we should allow to complete
+ 	if at all possible."
+ 	| unwindStarted unwindFinished p |
+ 	unwindStarted := unwindFinished := false.
+ 	p := [[] ensure:[
+ 			unwindStarted := true.
+ 			Processor yield.
+ 			unwindFinished := true.
+ 		]] fork.
+ 	self deny: unwindStarted.
+ 	Processor yield.
+ 	self assert: unwindStarted.
+ 	self deny: unwindFinished.
+ 	p terminate.
+ 	self assert: unwindFinished.!




More information about the Squeak-dev mailing list