hsac-fitnesse-plugin icon indicating copy to clipboard operation
hsac-fitnesse-plugin copied to clipboard

ENH: Table template, remove the limitation on order of table templates

Open teunisv opened this issue 2 years ago • 2 comments

Until now #27 is great. but I finally run into problem where order of them is an issue.

Normally an switch statement with table works fine (as long order are right). But to current project requires to me to define table (in example 'Decider') higher up in hierarchy, and therefor before table that this ones calls.

Flattened example:

#place this one below T2, and it works in current plugin
|table template|Decider|
|Init;                 |
|@{TD}                 |

|table template|Init         |
|clone symbol  |@{P0}        |
|clone symbol  |@{P1}        |
|$P2=          |clone symbol||

|table template|T0         |
|check|clone symbol|@{P0}|0|
|$P2= |clone symbol|@{P1}  |

|table template|T1         |
|check|clone symbol|@{P0}|3|
|$P2= |clone symbol|@{P1}  |

|table template|T2         |
|check|clone symbol|@{P0}|7|
|$P2= |clone symbol|@{P1}  |

|script|

|Decider     |
|TD|P0|P1|P2?|
|T0|0 |1 |1  |
|T1|3 |5 |5  |
|T2|7 |13|13 |

(no I cant place init inside decider in this project, although that would make it work)

teunisv avatar Nov 25 '22 14:11 teunisv

Could you do an !include to include the page with Decider after you defined T2 (or init)?

fhoeben avatar Nov 26 '22 12:11 fhoeben

Ideally it would not need the ‘init’, but doubt that would even be possible.

but since I got 30+ different inits not having to use include would be welcome change. If not then I be addicted 30+ includes 😀

teunisv avatar Nov 26 '22 17:11 teunisv