com.atlassian.jira.pageobjects.util
Class JavascriptRunner

java.lang.Object
  extended by com.atlassian.jira.pageobjects.util.JavascriptRunner

@Singleton
public class JavascriptRunner
extends Object

Class that can be used to execute JS on the browser while running WebDriver tests. It also contains methods to run useful common JS on the browser.

Since:
v6.2

Constructor Summary
JavascriptRunner()
           
 
Method Summary
 void clearWebSudo()
          Drop the user's Websudo authentication session.
 void destroyAllXsrfTokens()
          Wipe out all the XSRF tokens on the page.
 void execute(String script)
           
 void removeWorkflowDesignerUnloadHooks()
          The workflow designer adds unload hooks that can stop people leaving the page while it is doing something.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

JavascriptRunner

public JavascriptRunner()
Method Detail

destroyAllXsrfTokens

public void destroyAllXsrfTokens()
Wipe out all the XSRF tokens on the page.


clearWebSudo

public void clearWebSudo()
Drop the user's Websudo authentication session.


removeWorkflowDesignerUnloadHooks

public void removeWorkflowDesignerUnloadHooks()
The workflow designer adds unload hooks that can stop people leaving the page while it is doing something. This causes problems in the tests so we just remove these hooks in the tests. Ideally we should be able to wait for the WD to tell us that it is not busy. REF: CAS-580


execute

public void execute(String script)


Copyright © 2002-2014 Atlassian. All Rights Reserved.