Hi, Nagappan,<br><br>I followed the ldtp-tutorial and created a ldtprunner XML file named 'run.xml'. The XML file loaded a script named 'test.py' successfully. <br><br>In 'test.py', I loaded a ldtp Data XML file as follows. But I found that the 'data.xml' must reside in the same directory as 'run.xml'.<br>
<span style="font-family: courier new,monospace;"><br>dataXml = ldtputils.LdtpDataFileParser ('data.xml')</span><br><br>It causes some difficulites in arranging the ldtprunner xml files. We may have mutilple runner xml files comming from different directories to load the same 'test.py'. It forbid we write a hardcoded path for 'data.xml'. <br>
1) One solution is to use a flat directory structure. But it is too unnatural.<br>2) The other is to use os.getcwd() and os.chcwd() to change the working directory. But it seems I can't use '__file__' macro to get the current executing file's path information resolved.<br>
<br>Is there a better solution or hack available?<br><br>(It seems ldtp 1.7.1's ldtprunner implementation use 'execfile' to run the loaded script. I am not sure if there is another other standard method to solve the above issue)<br>
<br>Thanks<br>Scott Wang<br><br><br>