[View]  [Edit]  [Lock]  [References]  [Attachments]  [History]  [Home]  [Changes]  [Search]  [Help] 

test[scripting] 520 - Compiler operations

"operations"
| test |
test := (ScriptCompilerTest x: 1 y: 2) + 3.
test x = 4 ifFalse: [ self error: 'Must be 4' ].
test y = 5 ifFalse: [ self error: 'Must be 5' ].
4 * 5 = test xy ifFalse: [ self error: 'Must be 20' ].
test * 3 = (9 * 3) ifFalse: [ self error: 'Must be 9*3' ].
4 @ 5 = test point ifFalse: [ self error: 'Must be 4@5'].
(test select: [:i| i = 4]) = #(4) ifFalse: [ self error: 'Must be #(4)' ].