import |
fitnesse.slim.test |
Symbol Handling by Fixtures
If you need advanced symbol handling in your TableTable fixtures than your fixture code must handle this.
Advanced means that you assign to a symbol a value and need to reference this new value again in the same table.
Think if you really need this as it makes your code more complicated.
Load the symbol aware fixture
import |
fitnesse.slim.test.statementexecutorconsumer |
Included page: SymbolAssignmentAndReferenceOfTheSameInOneTable (edit)
import |
fitnesse.slim.test |
script | ||
$X= | echo int | 199 |
$Y= | echo int | 44 |
table: Table Table Inc First Col | ||
12 | $SymbolsInTableTableManagedByTheFixture= | # Assign to a new symbol |
$X | $Y= | # Assign to an existing symbol |
$Y | $Z= | # Assign a freshly assigned value |
Check the results Z is now 201 :)
script | |||
check | echo int | $Z | 201 |
check | echo int | $SymbolsInTableTableManagedByTheFixture | 13 |
The fixture handles a chain of assignments
script | ||
$X= | echo | 99 |
table: Table Table Inc First Col | |
$X | $X= |
$X | $X= |
$X | $X= |
$X | $X= |
$X | $X= |
$X | $Y= |
script | |||
check | echo | $X | 104 |
check | echo | $Y | 105 |