org.alfresco.webdrone.share
Class LoginPage

java.lang.Object
  extended by org.alfresco.webdrone.Page
      extended by org.alfresco.webdrone.share.SharePage
          extended by org.alfresco.webdrone.share.LoginPage
All Implemented Interfaces:
HtmlPage, Render

public class LoginPage
extends SharePage

Login Page object that holds all information and methods that can be found on the login page.

Since:
1.0
Author:
Michael Suzuki

Field Summary
 
Fields inherited from class org.alfresco.webdrone.share.SharePage
dojoSupport, WAIT_TIME_3000
 
Fields inherited from class org.alfresco.webdrone.Page
drone, maxPageLoadingTime, version
 
Constructor Summary
LoginPage(WebDrone drone)
          Constructor.
 
Method Summary
 boolean exists()
          Verify if login html element div is displayed.
 String getErrorMessage()
           
 boolean hasErrorMessage()
          Verify if error message is displayed.
 void loginAs(String username, String password)
          Logs user into the site by first finding the login panel,populating the fields and submitting the form.
 LoginPage render()
          Page renderer verifies the page has rendered by checking java script page loaded status is complete.
 LoginPage render(long time)
          Page renderer verifies the page has rendered by checking all elements are visible and loaded by the max limit time set.
 LoginPage render(RenderTime timer)
          Page renderer verifies the page has rendered by checking all elements are visible and loaded.
 
Methods inherited from class org.alfresco.webdrone.share.SharePage
basicRender, canResume, canResume, disbaleFileUploadFlash, elementRender, findButton, getCopyRight, getLogin, getNav, getPageTitle, getSearch, isJSMessageDisplayed, isLoggedIn, isLogoPresent, isTitlePresent, panelExists
 
Methods inherited from class org.alfresco.webdrone.Page
close, getDrone, getScreenShot, getTitle, isBrowserTitle, toString
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

LoginPage

public LoginPage(WebDrone drone)
Constructor.

Method Detail

render

public LoginPage render(RenderTime timer)
Description copied from interface: Render
Page renderer verifies the page has rendered by checking all elements are visible and loaded. To verify this assertion every page object that implements the method will contain logic to determine if the page has loaded completely in the given time set by the RenderTime.

Parameters:
timer - RenderTime time to wait
Returns:
HtmlPage page object response

render

public LoginPage render()
Description copied from interface: Render
Page renderer verifies the page has rendered by checking java script page loaded status is complete.

Returns:
HtmlPage object response

render

public LoginPage render(long time)
Description copied from interface: Render
Page renderer verifies the page has rendered by checking all elements are visible and loaded by the max limit time set.

Parameters:
time - waiting time
Returns:
HtmlPage page object response

exists

public boolean exists()
Verify if login html element div is displayed.

Returns:
true if panel is displayed

loginAs

public void loginAs(String username,
                    String password)
Logs user into the site by first finding the login panel,populating the fields and submitting the form.

Parameters:
username - String username value
password - String password value

hasErrorMessage

public boolean hasErrorMessage()
Verify if error message is displayed.

Returns:
true if div.bd is displayed

getErrorMessage

public String getErrorMessage()


Copyright © 2013. All Rights Reserved.