header
header
Main Menu
Home
Eviware Store
Downloads
Products
News
Forum
Eviware Blog
Search
FAQs
Customer Area
Support
Documentation
Tutorials
CookBook
Downloads
Forum
Login Form
Welcome, Guest. Please login or register.
November 21, 2008, 06:11:32 am
Username: Password:
Login with username, password and session length

Forgot your password?
 
How to add Properties(Names) from a text file to Property step
Welcome, Guest. Please login or register.
November 21, 2008, 06:11:32 am
Home Help Search Login Register
News: The Forums are up! Welcome to eviware.

+  Eviware Forum
|-+  soapUI
| |-+  soapUI
| | |-+  How to add Properties(Names) from a text file to Property step
« previous next »
Pages: [1] Print
Author Topic: How to add Properties(Names) from a text file to Property step  (Read 357 times)
Manoj
Newbie
*
Posts: 24


« on: January 08, 2008, 09:11:46 am »

Hi,
I am new to soapUI,
Is there any way we can write a groovy to load the property names in a .txt, .property or in xml to the property step automatically.
I have some 100's of property to be transfer.
I have to add each property now manually by clicking on the add property panel.

Please help me out on this.
Logged
omatzura
Administrator
Hero Member
*****
Posts: 1,420


« Reply #1 on: January 08, 2008, 02:43:50 pm »

Hi!

if your property-file is a "standard" property-file, you can use the "Load Properties" button in the properties-step window toolbar to load all properties and automatically add them.. otherwise a groovy script can of course be used as well.. use something like

def prop =
testRunner.testCase.testSteps["Properties"].addProperty( "myproperty" )

prop.value ="myvalue"

to create a property and set its value

Hope this helps!

regards,

/Ole
eviware.com
Logged
Manoj
Newbie
*
Posts: 24


« Reply #2 on: January 08, 2008, 05:47:34 pm »

Hi Ole,

Thank you for your quick answar.
I want to read the property names and value from a file and display in the Property step.
Is there any way we can read from a xml file and assign it to property step?


 
Logged
omatzura
Administrator
Hero Member
*****
Posts: 1,420


« Reply #3 on: January 08, 2008, 07:02:47 pm »

Hi!

can you show/attach the file you want to read so I can get a better idea?

regards!

/Ole
eviware.com
Logged
Manoj
Newbie
*
Posts: 24


« Reply #4 on: January 09, 2008, 07:50:15 am »

Hi Ole,

Thanks for you reply.
I got the solution by adding the addProperty.  Smiley
Thank you so much once again for your quick support.
Logged
Pages: [1] Print 
« previous next »
Jump to:  


Login with username, password and session length

Powered by MySQL Powered by PHP Powered by SMF 1.1.2 | SMF © 2006-2007, Simple Machines LLC Valid XHTML 1.0! Valid CSS!
header header
header
header