cancel
Showing results for 
Search instead for 
Did you mean: 

How to use properties from external file in automatically run SOAP UI tests?

Highlighted
New Contributor

How to use properties from external file in automatically run SOAP UI tests?

How to use properties from external file in automatically run SOAP UI tests?

 

Hello community,

I want to keep my Web Service username and password separately from SOAP UI Test XML file.

So, I save username and password as custom properties in external file called properties.xml.

 

But the problem is that after I manually import the property values (defined on the project level) and save the test, the values are added to the test XML file distinctly.

 

So, anybody who will open the test XML file after me, will be able to read the username and password in my property values. Which I do not want.

 

Inside the test XML file it looks like this:
<con:name>USERNAME</con:name><con:value>!MYUSERNAMEVALUE</con:value></con:property><con:property><con:name>PASSWORD</con:name><con:value>!MYPASSWORD</con:value>

 

Can I use reference to my username and password through the external file properties.xml, while automatically running the test, but not show values in test XML?

 

I thought this configuration would work:

<con:name>USERN</con:name><con:value>${projectDir\properties#USERNAME}</con:value></con:property><con:property><con:name>PASSWORD</con:name><con:value>${projectDir\properties#PASSWORD}</con:value>

 

or this one:

 

<con:name>USERN</con:name><con:value>${projectDir\properties.xml#USERNAME}</con:value></con:property><con:property><con:name>PASSWORD</con:name><con:value>${projectDir\properties.xml#PASSWORD}</con:value>

 

But they are not resolving the propertiy values correctly.

 

Please help. Thank you!

 

2 REPLIES 2
Highlighted
Community Leader

Re: How to use properties from external file in automatically run SOAP UI tests?

@youtube2019 ,

 

Hope below article will help you.

 

working-with-properties

 


Click "Accept as Solution" if my answer has helped,
Remember to give "Kudos" 🙂 ↓↓↓↓↓



Thanks and Regards,
Himanshu Tayal
Highlighted
New Contributor

Re: How to use properties from external file in automatically run SOAP UI tests?

Hello

 

 

New Here?
Join us and watch the welcome video:
Top Kudoed Authors