rollno748 / Extended-csv-dataset-config

This plugin will enable Apache JMeter users to have similar parameter advantage as LoadRunner
MIT License
25 stars 7 forks source link

相对路径读取参数化文件失败 #5

Closed yangfan112 closed 1 year ago

yangfan112 commented 2 years ago

image image

jmx和csv文件在同一路径下,相对路径读取文件内容失败 错误信息: java.lang.IllegalArgumentException: Could not read file header line for file userInfo.csv

yangfan112 commented 2 years ago

image Script_jmx.zip

rollno748 commented 2 years ago

Hello Thanks for opening an issue.

I don't think its an issue here. The problem I see is due to the script location.

If you are providing the csv filename alone - The JMeter needs to be start on the same location as the jmx.

According to your screenshot, Please follow the steps

  1. Open your command prompt on the jmx location (F:/test/) or open your command prompt and navigate to F:/test
  2. Start the jmeter in that location (jmeter -t login.jmx) - If you haven't set the JMETER_HOME property to environment variable, then you can provide the full path to start the jmeter.
  3. Try the script now - it should work

If the Filepath was not given then JMeter will always try to look for the file in the same location where it was started.

So, I don't think its an issue

rollno748 commented 2 years ago

I wil close this issue based upon your comments

yangfan112 commented 2 years ago

非常感谢,根据你的提示,我重现验证了该现象,仅需把参数化文件放置JMETER_HOME目录即可正常运行,但该方式不便于jmx文件和csv文件管理,且与原生CSV Data Set Config使用方式有差异,建议保持一致,非常感谢你的开源贡献。 image

rollno748 commented 2 years ago

Thanks for testing - I will keep this open as an enhancement I am working on a new UI part - Will patch this along with that

Thanks again for letting me know, Please hit a star - if you like my work.

rollno748 commented 1 year ago

I have pushed the changes for the new version (2.0) This issue is fixed