Verify Part of an Object

I am trying to verify part of an object on a page. I can identify the text with an xpath, the problem is the xpath has a value of Date and Time, I only want to verify the date. The following code is what I am currently using, but the time can verify by a few minutes and that causes the test to fail.

if (!(WebUI.verifyMatch(selenium.getText('xpath=(.//*[normalize-space(text()) and normalize-space(.)=\'Started\'])[1]/following::td[1]'), 
    Today + ' 2:00:00 AM', false))) {
    log.logInfo('Sailpoint QUAL Perform Identity Request Maintenance daily did not run')
}

Does anyone have any suggestions to help me out?

if (!(WebUI.verifyMatch(selenium.getText('xpath=(.//*[normalize-space(text()) and normalize-space(.)=\'Started\'])[1]/following::td[1]'), 
    '^.*'+ Today + '.*$', true))) {    log.logInfo('Sailpoint QUAL Perform Identity Request Maintenance daily did not run')
}

try use regexp

Andrej Podhajský said:

if (!(WebUI.verifyMatch(selenium.getText('xpath=(.//*[normalize-space(text()) and normalize-space(.)=\'Started\'])[1]/following::td[1]'), 
'^.*'+ Today + '.*$', true))) {    log.logInfo('Sailpoint QUAL Perform Identity Request Maintenance daily did not run')

}


  
  
try use regexp

  

That works,

Thanks

UR welcome