Hi Marcel,<br>
<br>
> @Christoph(ct): Please simplify the b's and the c's as discussed here: http://lists.squeakfoundation.org/pipermail/squeak-dev/2020-March/207963.html<br>
<br>
given the complexity of compiler inlinings, I would feel more safe if we kept all three assertions at least for the '*Inlined' tests. Then again, the tests would look more uniform if we also kept all assertions in their non-inlined pendants. What do you think? :-)<br>
<br>
Best,<br>
Christoph<br>
<br>
<font color="#808080">---<br>
</font><font color="#808080"><i>Sent from </i></font><font color="#808080"><i><a href="https://github.com/hpi-swa-lab/squeak-inbox-talk"><u><font color="#808080">Squeak Inbox Talk</font></u></a></i></font><br>
<br>
On 2021-11-18T09:47:39+00:00, commits@source.squeak.org wrote:<br>
<br>
> Marcel Taeumel uploaded a new version of KernelTests to project The Trunk:<br>
> http://source.squeak.org/trunk/KernelTests-mt.408.mcz<br>
> <br>
> ==================== Summary ====================<br>
> <br>
> Name: KernelTests-mt.408<br>
> Author: mt<br>
> Time: 18 November 2021, 10:47:39.0372 am<br>
> UUID: 43e74627-a769-7c42-8545-9f999e1d21fb<br>
> Ancestors: KernelTests-mt.407<br>
> <br>
> Complements Kernel-mt.1422<br>
> <br>
> @Christoph(ct): Please simplify the b's and the c's as discussed here: http://lists.squeakfoundation.org/pipermail/squeak-dev/2020-March/207963.html<br>
> <br>
> =============== Diff against KernelTests-mt.407 ===============<br>
> <br>
> Item was added:<br>
> + ----- Method: ObjectTest>>testCaseOf (in category 'tests') -----<br>
> + testCaseOf<br>
> + <br>
> +     | a b c dict |<br>
> +     a := Object new.<br>
> +     b := Object new.<br>
> +     c := Object new.<br>
> +     dict := {<br>
> +         [a] -> [b].<br>
> +         [b] -> [c].<br>
> +         [c] -> [a] }.<br>
> +     self assert: b equals: (a caseOf: dict).<br>
> +     self assert: c equals: (b caseOf: dict).<br>
> +     self assert: a equals: (c caseOf: dict).<br>
> +     self should: [nil caseOf: dict] raise: Error.!<br>
> <br>
> Item was added:<br>
> + ----- Method: ObjectTest>>testCaseOfInlined (in category 'tests') -----<br>
> + testCaseOfInlined<br>
> + <br>
> +     | a b c |<br>
> +     a := Object new.<br>
> +     b := Object new.<br>
> +     c := Object new.<br>
> +     self assert: b equals: (a caseOf: { [a] -> [b]. [b] -> [c]. [c] -> [a] }).<br>
> +     self assert: c equals: (b caseOf: { [a] -> [b]. [b] -> [c]. [c] -> [a] }).<br>
> +     self assert: a equals: (c caseOf: { [a] -> [b]. [b] -> [c]. [c] -> [a] }).<br>
> +     self should: [nil caseOf: { [a] -> [b]. [b] -> [c]. [c] -> [a] }] raise: Error.!<br>
> <br>
> Item was added:<br>
> + ----- Method: ObjectTest>>testCaseOfOtherwise (in category 'tests') -----<br>
> + testCaseOfOtherwise<br>
> + <br>
> +     | a b c dict |<br>
> +     a := Object new.<br>
> +     b := Object new.<br>
> +     c := Object new.<br>
> +     dict := {<br>
> +         [a] -> [b].<br>
> +         [b] -> [c].<br>
> +         [c] -> [a] }.<br>
> +     <br>
> +     self assert: b equals: (a caseOf: dict otherwise: [self fail]).<br>
> +     self assert: c equals: (b caseOf: dict otherwise: [self fail]).<br>
> +     self assert: a equals: (c caseOf: dict otherwise: [self fail]).<br>
> +     self assert: 42 equals: (nil caseOf: dict otherwise: [42]).<br>
> +     self assert: 42 equals: (6 caseOf: dict otherwise: [:x | x * 7]).!<br>
> <br>
> Item was added:<br>
> + ----- Method: ObjectTest>>testCaseOfOtherwiseInlined (in category 'tests') -----<br>
> + testCaseOfOtherwiseInlined<br>
> + <br>
> +     | a b c |<br>
> +     a := Object new.<br>
> +     b := Object new.<br>
> +     c := Object new.<br>
> +     self assert: b equals: (a caseOf: { [a] -> [b]. [b] -> [c]. [c] -> [a] } otherwise: [self fail]).<br>
> +     self assert: c equals: (b caseOf: { [a] -> [b]. [b] -> [c]. [c] -> [a] } otherwise: [self fail]).<br>
> +     self assert: a equals: (c caseOf: { [a] -> [b]. [b] -> [c]. [c] -> [a] } otherwise: [self fail]).<br>
> +     self assert: 42 equals: (nil caseOf: { [a] -> [b]. [b] -> [c]. [c] -> [a] } otherwise: [42]).<br>
> +     self assert: 42 equals: (6 caseOf: { [a] -> [b]. [b] -> [c]. [c] -> [a] } otherwise: [:x | x * 7]).!<br>
> <br>