question

kmd6076 avatar image
kmd6076 asked LarryVeilleux edited

iTestRT - [info] substitution for test case path

One of the first steps in a test case is to read in a config file with basic info. The path to that config file varies on the environment that it is executed in so I use the [info testCaseProject main] substitution to get the path at execution time. This works when run in the UI but when running via iTestRT it fails to insert the value for [info testCaseProject main]. Is this supported? ![alt text][1] [1]: /storage/temp/4250-itestrt_nosubstitutionfortestcasepath.jpg
iTestiTest Runtime (itestrt)
10 |950

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

JeffJ avatar image
JeffJ answered
Since iTestRT operates on itar files and not a workspace, some of the "info" commands have no meaning. To accomplish what you're looking for, don't use the "project://" method of finding the file. Instead, use relative pathing to get to the file. For example, if the test case is in the "project://my_project/test_cases" directory and the config file is in "project://my_project/config", you can address the file relatively with "../config". This will eliminate the need to know the project name.
10 |950

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

amichaels avatar image
amichaels answered
It looks like you're missing a forward slash in the project URI for that file that your arrow points to. project://config_files/set_env.fftc look at the line just above your arrow. That URI has the correct 2 forward slashes.
10 |950

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

Write an Answer

Hint: Notify or tag a user in this post by typing @username.

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.