Forum Discussion
HKosova
7 years agoSmartBear Alumni (Retired)
You can use a project setup script to initialize these values using Groovy:
def now = new Date() def tomorrow = now + 1 def futureDate = now + 1000 project.setPropertyValue( "effectiveEntryDateSameDay", now.format("M/d/yy") ) project.setPropertyValue( "effectiveEntryDateWithTimeStamp", tomorrow.format("M/d/yyyy HH:mm") )
// etc.
Groovy Date class reference:
http://docs.groovy-lang.org/latest/html/groovy-jdk/java/util/Date.html
Format strings:
http://docs.oracle.com/javase/8/docs/api/java/text/SimpleDateFormat.html
- CByler7 years agoContributor
I've never used a Project Setup Script, so I will research that today. Thank you Helen for the quick response!
Related Content
- 5 years agoKrishna_Kumar
- 2 years agoTestQA1
- 3 years agoloricotton