we are waiting for the current `save` button to become stale, and if Jenkins is slow enough and maven tests are quick enough that will happen as soon as we get the response from Jenkins.
in this case it is a 302 redirect so we really need a way to know either what the submit endpoint is (so we keep waiting as long as that is the driver.currenturl) or the expected endpoint so we know to wait until the driver.currenturl is the expected page.
the first would have some issues when saving a form ends up with the same URL as the form submission (by using some form of view in the Jenkins / plugin code).
we are waiting for the current `save` button to become stale, and if Jenkins is slow enough and maven tests are quick enough that will happen as soon as we get the response from Jenkins.
in this case it is a 302 redirect so we really need a way to know either what the submit endpoint is (so we keep waiting as long as that is the driver.currenturl) or the expected endpoint so we know to wait until the driver.currenturl is the expected page.
the first would have some issues when saving a form ends up with the same URL as the form submission (by using some form of view in the Jenkins / plugin code).