There is a string: "Login 1234 has been created" Here 1234 is a dynamic text. How can I compare this entire string in one shot.
I do know of the way to do split using " "(space) and then getting into array,asserting it using regex:
assertTrue(dynamicText.substring(1, 5).equals([0-9]+));
but that takes more lines of code. I want to know if there is any efficient way of coding other than this. Thanks.