Forum Discussion
Cizo89
13 years agoFrequent Contributor
Hi mchelikani,
try this script, it should help you:
Regards,
Marek
try this script, it should help you:
def xpathAssertion = testRunner.testCase.testSteps["name_of_your_step"].addAssertion("XPath Match")
xpathAssertion.setPath("your_xpath")
xpathAssertion.setExpectedContent("expected_result")
xpathAssertion.setName("your_required_name_xpath")
def containsAssertion = testRunner.testCase.testSteps["name_of_your_step"].addAssertion("Contains")
containsAssertion.setToken("your_expected_string")
containsAssertion.setName("your_required_name_contains")
Regards,
Marek