Forum Discussion

mohanbabu400's avatar
mohanbabu400
Occasional Contributor
8 years ago
Solved

Specify/setup Groovy Scripts location when executing the SOAPUI project using testrunner.sh

Hello -

I would like to execute soap-ui projects from command line using testrunner.sh. On UI, under preferences, there is an option to specify script library location for use in the test cases. How do i specify or setup ReadyAPI to look for the script at a desired location while executing a SOAPUI project from command line using testrunner.sh ?

 

I am using ReadyAPI 1.7.0

Attached the preferences UI with script library option

 

 

Appreciate any knowledge from experts

 

thanks,

/Mohan

  • Looks like "soapui-settings.xml" will be created under home directory of the current user when ReadyAPI UI is launched. I installed ReadyAPI on headless Linux machine and never launched UI as my VM didn't have X-windows installed.

    soapui-settings.xml contains the preferences( Ex: path of the script library ). So without soapui-settings.xml executing the SOAPUI project that contains groovy script via testrunner.sh will fail.

     

    Solution is either install Ready API and edit the soapui-settings.xml with the respective paths and use it on head less machine OR launch the ReadyAPI at least one time before executing the tests from testrunner.sh

     

    Script location can be changed in the soapui-settings.xml to point to the desired location ( its same as in the UI)

2 Replies

  • nmrao's avatar
    nmrao
    Champion Level 3
    Looks you already set the path in the preferences. So, now all you need to provide is the same settings file while running it command line using testrunner. I am sure you will find the option to pass the settings file commandline.
  • mohanbabu400's avatar
    mohanbabu400
    Occasional Contributor

    Looks like "soapui-settings.xml" will be created under home directory of the current user when ReadyAPI UI is launched. I installed ReadyAPI on headless Linux machine and never launched UI as my VM didn't have X-windows installed.

    soapui-settings.xml contains the preferences( Ex: path of the script library ). So without soapui-settings.xml executing the SOAPUI project that contains groovy script via testrunner.sh will fail.

     

    Solution is either install Ready API and edit the soapui-settings.xml with the respective paths and use it on head less machine OR launch the ReadyAPI at least one time before executing the tests from testrunner.sh

     

    Script location can be changed in the soapui-settings.xml to point to the desired location ( its same as in the UI)