Canoo/Ant属性在任务和步骤中的作用域不同?

Canoo/Ant属性在任务和步骤中的作用域不同?,ant,properties,canoo,Ant,Properties,Canoo,我们设置了一个CanooWebTest来测试多语言环境应用程序。对于每个区域设置,webtest从属性文件加载许多属性 在下面的示例中,locale_代码、htaccess.username、htaccess.password和webtest_url都在这样的属性文件中定义 在webtest任务本身中,${locale_code}被替换,导致(例如) “国家目录或朋友” 然而,调用步骤中的属性并没有被替换,描述显示为“Einstieg Hauptseite${webtest_url}”,即使它们

我们设置了一个CanooWebTest来测试多语言环境应用程序。对于每个区域设置,webtest从属性文件加载许多属性

在下面的示例中,locale_代码、htaccess.username、htaccess.password和webtest_url都在这样的属性文件中定义

在webtest任务本身中,${locale_code}被替换,导致(例如) “国家目录或朋友”

然而,调用步骤中的属性并没有被替换,描述显示为“Einstieg Hauptseite${webtest_url}”,即使它们只被正确地替换在它上面的一行


...
很明显,已加载特定于语言环境的属性文件,我们可以在文件中更改webtest_url(例如),并在webtest名称中正确替换新值


我对ant几乎一无所知(我接触过Canoo),对Canoo webtest知之甚少(我最近继承了他们),所以我甚至不确定这是一个webtest还是一个ant问题。

您可能正在使用ant 1.8
不评估动态属性。
您必须使用Ant 1.7

见问题

<project default="test">
  <import file="../../definitions.xml"/>
  <target name="test" depends="wt.defineMacros">
    <webtest name="CatalogueOrderFriendsCountry ${locale_code} ${webtest_url}">

      <invoke username="${htaccess.username}" password="${htaccess.password}" url="${webtest_url}" description="Einstieg Hauptseite ${webtest_url}"/>
      ...