#REFACTORING by cg
class: RegressionTests::OperationInQueueTests
changed: #test3
race
--- a/RegressionTests__OperationInQueueTests.st Tue Apr 02 11:12:16 2019 +0200
+++ b/RegressionTests__OperationInQueueTests.st Tue Apr 02 15:34:40 2019 +0200
@@ -64,40 +64,40 @@
self assert:(opQ size == 0).
p0 := [
- opQ scheduleOperation:[ Delay waitForSeconds:3.].
+ opQ scheduleOperation:[ Delay waitForSeconds:1.].
] fork.
p1 := [
- rslt1 := opQ scheduleOperation:(val1 := '1').
+ rslt1 := opQ scheduleOperation:[val1 := '1'].
] fork.
p2 := [
- rslt2 := opQ scheduleOperation:(val2 := '2').
+ rslt2 := opQ scheduleOperation:[val2 := '2'].
] fork.
p3 := [
- rslt3 := opQ scheduleOperation:(val3 := '3').
+ rslt3 := opQ scheduleOperation:[val3 := '3'].
] fork.
Delay waitForSeconds:0.5.
self assert:((sz := opQ size) == 3).
p1b := [
- rslt1b := opQ scheduleOperation:(val1b := '1').
+ rslt1b := opQ scheduleOperation:[val1b := '1'].
] fork.
p2b := [
- rslt2b := opQ scheduleOperation:(val2b := '2').
+ rslt2b := opQ scheduleOperation:[val2b := '2'].
] fork.
p3b := [
- rslt3b := opQ scheduleOperation:(val3b := '3').
+ rslt3b := opQ scheduleOperation:[val3b := '3'].
] fork.
- Delay waitForSeconds:0.5.
- self assert:(opQ size == 3).
+ Delay waitForSeconds:0.1.
+ self assert:(opQ size == 6).
- Delay waitForSeconds:3.
+ Delay waitForSeconds:1.
self assert:((sz := opQ size) == 0).
self assert:(val1 == rslt1).
@@ -114,7 +114,7 @@
self assert:false message:'test did not finish within 30 seconds'
].
- "Modified: / 03-07-2018 / 11:48:12 / Claus Gittinger"
+ "Modified: / 02-04-2019 / 15:34:28 / Claus Gittinger"
! !
!OperationInQueueTests class methodsFor:'documentation'!