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.
January 08, 2009, 10:26:41 pm
Username: Password:
Login with username, password and session length

Forgot your password?
 
set a date from a testcase property
Welcome, Guest. Please login or register.
January 08, 2009, 10:26:41 pm
Home Help Search Login Register
News: The Forums are up! Welcome to eviware.

+  Eviware Forum
|-+  soapUI
| |-+  soapUI
| | |-+  set a date from a testcase property
« previous next »
Pages: [1] Print
Author Topic: set a date from a testcase property  (Read 594 times)
Christoph Schwarz
Newbie
*
Posts: 17


« on: June 11, 2008, 03:35:20 pm »

hi,

i have a testcase where i have a date field where i always want to have the actual date from today and not a fixed date from the datepicker. so i did a simple groovy script to generate todays date, store it as a testsuite property and would like to import that testsuite property into the date field.
but whenever i close the request and reopen it i have the date in there and not the property value anymore.

is there a way to keep the property value?

thanks,
Christoph
Logged
omatzura
Administrator
Hero Member
*****
Posts: 1,666


« Reply #1 on: June 11, 2008, 03:42:02 pm »

Hi Chris,

hmm.. what exactly are you entering into the field that gets replaced with the actual date?

regards,

/Ole
eviware.com
Logged
Christoph Schwarz
Newbie
*
Posts: 17


« Reply #2 on: June 11, 2008, 04:45:05 pm »

Hi Ole,

i want to do something like this request from a database:

   <soapenv:Body>
      <sec:GetList>
         <!--Optional:-->
         <sec:AuditLogEntryRequest>
            <!--Optional:-->
            <sec1:UserName>AnyUser</sec1:UserName>
            <!--Optional:-->
            <sec1:Module>Module</sec1:Module>
            <!--Optional:-->
            <sec1:EventContract>IContract</sec1:EventContract>
            <!--Optional:-->
            <sec1:EventOperation>Login</sec1:EventOperation>
            <!--Optional:-->
            <sec1:CreatedFrom>2008-06-10T00:00:00.000+02:00</sec1:CreatedFrom>
            <!--Optional:-->
            <sec1:CreatedUntil>2008-06-12T00:00:00.000+02:00</sec1:CreatedUntil>
         </sec:AuditLogEntryRequest>

where i would like to replace the Date in <sec1:CreatedFrom>2008-06-10T00:00:00.000+02:00</sec1:CreatedFrom> with a date from a property: ${#TestSuite#TodaysDate} (currently set to Wed Jun 11 16:39:07 CEST 2008)

so the createdFrom should look like this: <sec1:CreatedFrom>${#TestSuite#TodaysDate}</sec1:CreatedFrom>

thanks,
Chris
Logged
omatzura
Administrator
Hero Member
*****
Posts: 1,666


« Reply #3 on: June 11, 2008, 05:58:00 pm »

Hi,

ok.. and you're saying that when you enter this property-expansion in the form field, it gets expanded/removed when you open/close the request? Which version/build are you running?

regards!

/Ole
eviware.com
Logged
Christoph Schwarz
Newbie
*
Posts: 17


« Reply #4 on: June 12, 2008, 08:28:43 am »

Hi,

yes, i try to select it on the form and it is displayed, but when i switch to the xml then there the date is still shown and when i switch back to the form the date there is shown again.

i originally created the request in the service with a date set, then copied it to a testcase and wanted to select the property extension.

i tried to enter it manually in the xml and this works.

i am using version 2.0.2

regards,
Chris
Logged
Marcel Brökel
Newbie
*
Posts: 9


« Reply #5 on: June 12, 2008, 03:08:37 pm »

i got the same problem. Maybe the date format fields are not accesable with properties ?

have you tried to paste the propertyextension directly into the xml ?
Logged
omatzura
Administrator
Hero Member
*****
Posts: 1,666


« Reply #6 on: June 13, 2008, 11:06:56 am »

Hi everyone!

this is fixed in next release, sorry for the inconvenience..

regards!

/Ole
eviware.com
Logged
Christoph Schwarz
Newbie
*
Posts: 17


« Reply #7 on: June 13, 2008, 11:57:35 am »

Hi,

for me it works when i manually copy the property string in the XML like this: <sec1:CreatedFrom>${#TestSuite#TodaysDate}</sec1:CreatedFrom>

regards
Chris
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