com.atlassian.confluence.pageobjects
Class WebdriverUtils
java.lang.Object
com.atlassian.confluence.pageobjects.WebdriverUtils
public class WebdriverUtils
- extends java.lang.Object
A utility class for webdriver tests.
Constructor Summary |
WebdriverUtils(com.atlassian.pageobjects.elements.PageElementFinder pageElementFinder,
org.openqa.selenium.JavascriptExecutor executor)
|
Method Summary |
java.lang.String |
getMetadata(java.lang.String name)
Returns the meta tag's content. |
long |
getMetadataLong(java.lang.String name)
|
void |
waitForPageChange(com.atlassian.pageobjects.elements.PageElement elementToClick)
This method is useful when a new page is loaded via javascript. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
WebdriverUtils
public WebdriverUtils(com.atlassian.pageobjects.elements.PageElementFinder pageElementFinder,
org.openqa.selenium.JavascriptExecutor executor)
waitForPageChange
public void waitForPageChange(com.atlassian.pageobjects.elements.PageElement elementToClick)
- This method is useful when a new page is loaded via javascript. e.g. when the Create button in the blueprint dialogs
is clicked and the newly created page/space is loaded. This implementation is a little hacky but the best solution
at the time of writing.
- Parameters:
toClick
- the element to click before waiting for the page to change
getMetadata
public java.lang.String getMetadata(java.lang.String name)
- Returns the meta tag's content. Note that you do not have to pass the "ajs-" prefix to the name, this is
done for you.
- Parameters:
name
- name of the meta tag, excluding the ajs- prefix
- Returns:
- the content in the meta tag
getMetadataLong
public long getMetadataLong(java.lang.String name)
Copyright © 2003-2013 Atlassian. All Rights Reserved.