getUrl not returning new Url after submitting form

Hello
Well, I find this a very basic issue, but I tried many things unsuccessfuly.

We have a form is inside /register html, and after POST request the web app goes to /register/success. Browser effectively shows the new page. However, it seems that WebUI.getUrl() does not change its response:

WebUI.submit(findTestObject(‘Page_Registrer/Register/form’))

WebUI.waitForPageLoad(60)

println(WebUI.getUrl()) // prints “/register”, it should be “/register/success”

assert WebUI.getUrl().contains(“success”) // fails

Any Idea? thanks