I’ve a file in local path of my test host, and I want to access it in my script. This is how I did:
if file DataPath exists then put file DataPath into Data repeat with n=1 to the number of lines in Data get line n of Data put it into Line -- Process the data here end repeat end if
If DataPath points to a network path (e.g. /users//data.txt), then Eggplant managed to detect the existence of this file and read it as expected. However, if DataPath points to a local path (e.g. C:<name>\data.txt), Eggplant will never got the chance to enter this if block. It didn’t able to detect the existence of this file. I’m pretty sure that the file is there.
My best guess at this point is that Eggplant couldn’t recognize path like C:<name>\data.txt is a local path in test host, and it refers to nowhere?? What should I do in order to instruct Eggplant to read a file from local path in (windows) test host?