Handle modal dialogue which will block all tests in the cms

In the CMS, the modal dialogue will block all the following texts. Now it's handled in failed test step, triggered by navigating away from current page.