com.atlassian.confluence.webdriver.rules
Class VisitNoopAndCancelAlertsRule

java.lang.Object
  extended by org.junit.rules.TestWatcher
      extended by com.atlassian.confluence.webdriver.rules.VisitNoopAndCancelAlertsRule
All Implemented Interfaces:
org.junit.rules.TestRule
Direct Known Subclasses:
CancelAnyEditorRule

public class VisitNoopAndCancelAlertsRule
extends org.junit.rules.TestWatcher

Cancels any editor, after the test completes, to prevent getting stuck on modal dialogs due to the dirty page warning.


Constructor Summary
VisitNoopAndCancelAlertsRule()
           
 
Method Summary
 void finished(org.junit.runner.Description description)
          Navigates to a blank page and cleans up any dialogs attempting to block that navigation.
 
Methods inherited from class org.junit.rules.TestWatcher
apply, failed, starting, succeeded
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

VisitNoopAndCancelAlertsRule

public VisitNoopAndCancelAlertsRule()
Method Detail

finished

public void finished(org.junit.runner.Description description)
Navigates to a blank page and cleans up any dialogs attempting to block that navigation. Note that code.google.com/p/chromedriver/issues/detail?id=161 makes us need to catch an exception.

Overrides:
finished in class org.junit.rules.TestWatcher


Copyright © 2003-2014 Atlassian. All Rights Reserved.