I\'m testing my web application using Selenium IDE. There are test cases in which I have to assert that today\'s date appears on the page. I cannot hard code today\'s date in th
Try this in Selenium IDE. It will print the timestamp as yyyymmddhhmmss.
storeExpression
javascript{var date = new Date();date.getFullYear() + '' + ((date.getMonth()+1<10)?('0'+(date.getMonth()+1)):(date.getMonth()+1)) + '' + ((date.getDate()+1<10)?('0'+(date.getDate()+1)):(date.getDate()+1)) + '' + date.getHours() + '' + date.getMinutes() + '' + date.getSeconds();}
date
echo
${date}