简体   繁体   English

Fitnesse Slim夹具变量替换失败

[英]fitnesse slim fixture variable substitution failure

Currently I have a FitNesse Slim fixture written with a quick and easy method for processing: 目前,我有一个用快速简便的方法编写的FitNesse Slim夹具:

public List<List<String>> doTable(List<List<String>> rows)

Everything is working just fine except for one problem: page variables/expressions. 除了一个问题:页面变量/表达式,其他所有东西都工作正常。

On the parent page I have a date/time variable defined: 在父页面上,我定义了一个日期/时间变量:

!define myvar {!today (mmddhms)}

On the child page I have my table defined for processing following a similar pattern to the RESTFixture that is available on GitHub: 在子页面上,我按照与GitHub上可用的RESTFixture类似的模式定义了要处理的表:

!| Table:my.domain.MyFixture |
| let | myinnervar | const | ${myvar} |
| uri | http://someuri.com:12345 |
| etc | etc.etc.etc. |



The problem is: 问题是:

The ${myvar} specification does not evaluate properly. ${myvar}规范无法正确评估。 Instead of evaluating to a value such as 071511718 it shows up as the actual expression: !today (mmddhms) . 它没有显示为诸如071511718的值,而是显示为实际表达式: !today (mmddhms) I need it to evaluate as the proper expression. 我需要它来评估为正确的表达方式。

In the RESTFixture table that is set up identically and anywhere else it evaluate just fine. 在RESTFixture表中,该表设置相同,并且在其他任何地方进行评估都很好。 However, I am not seeing where the specialized processing code is defined that allows it to properly evaluate. 但是,我看不到在哪里定义了专门的处理代码以使其能够正确评估。

Can anyone point to the appropriate code in that Fixture or just point me to some documentation. 任何人都可以指向该装置中的适当代码,或者仅指向一些文档。 I'm not seeing anything online. 我没有看到任何在线内容。

You're using a literal table which means wiki markup is not interpreted inside the table. 您正在使用文字表,这意味着在表内不解释Wiki标记。 Use a plain table and escape the cells that you don't want interpreted as wiki markup 使用普通表并转义不需要解释为Wiki标记的单元格

| Table:my.domain.MyFixture |
| let | myinnervar | const | ${myvar} |
| uri | !-http://someuri.com:12345-! |
| etc | etc.etc.etc. |

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM