org.viewaframework.test.component
Class AbstractButtonTrapper<T extends AbstractButton>

java.lang.Object
  extended by org.viewaframework.test.component.AbstractComponentTrapper<T>
      extended by org.viewaframework.test.component.AbstractButtonTrapper<T>
Type Parameters:
T -
All Implemented Interfaces:
ApplicationTrapperAware, ViewTrapperAware, Trapper<T>
Direct Known Subclasses:
ButtonTrapper, MenuItemTrapper

public abstract class AbstractButtonTrapper<T extends AbstractButton>
extends AbstractComponentTrapper<T>

Author:
Mario Garcia

Constructor Summary
AbstractButtonTrapper(ApplicationTrapper applicationTrapper, String componentName)
           
AbstractButtonTrapper(ApplicationTrapper applicationTrapper, String viewId, String componentName)
           
 
Method Summary
 AbstractButtonTrapper<T> click()
           
 AbstractButtonTrapper<T> click(long millis)
           
 AbstractComponentTrapper<T> requireEnabled()
          Checks that the component is enabled otherwise the test will fail
 AbstractComponentTrapper<T> requireEnabled(boolean enabled)
          Checks whether the component is enabled or not
 AbstractComponentTrapper<T> requireText(String text)
           
 AbstractComponentTrapper<T> requireToolTipText(String text)
           
 AbstractComponentTrapper<T> requireVisible()
          Checks the component is visible otherwise the test will fail
 AbstractComponentTrapper<T> requireVisible(boolean visible)
          Checks whether the component is visible or not
 
Methods inherited from class org.viewaframework.test.component.AbstractComponentTrapper
applicationTrapper, getTarget, setTarget, view, view
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface org.viewaframework.test.Trapper
getType, log
 

Constructor Detail

AbstractButtonTrapper

public AbstractButtonTrapper(ApplicationTrapper applicationTrapper,
                             String componentName)
Parameters:
applicationTrapper -
componentName -

AbstractButtonTrapper

public AbstractButtonTrapper(ApplicationTrapper applicationTrapper,
                             String viewId,
                             String componentName)
Parameters:
applicationTrapper -
viewId -
componentName -
Method Detail

click

public AbstractButtonTrapper<T> click()
Returns:

click

public AbstractButtonTrapper<T> click(long millis)
Parameters:
millis -
Returns:

requireEnabled

public AbstractComponentTrapper<T> requireEnabled()
Description copied from class: AbstractComponentTrapper
Checks that the component is enabled otherwise the test will fail

Specified by:
requireEnabled in class AbstractComponentTrapper<T extends AbstractButton>
Returns:

requireEnabled

public AbstractComponentTrapper<T> requireEnabled(boolean enabled)
Description copied from class: AbstractComponentTrapper
Checks whether the component is enabled or not

Specified by:
requireEnabled in class AbstractComponentTrapper<T extends AbstractButton>
Returns:

requireText

public AbstractComponentTrapper<T> requireText(String text)
Parameters:
text -
Returns:

requireToolTipText

public AbstractComponentTrapper<T> requireToolTipText(String text)
Parameters:
text -
Returns:

requireVisible

public AbstractComponentTrapper<T> requireVisible()
Description copied from class: AbstractComponentTrapper
Checks the component is visible otherwise the test will fail

Specified by:
requireVisible in class AbstractComponentTrapper<T extends AbstractButton>
Returns:

requireVisible

public AbstractComponentTrapper<T> requireVisible(boolean visible)
Description copied from class: AbstractComponentTrapper
Checks whether the component is visible or not

Specified by:
requireVisible in class AbstractComponentTrapper<T extends AbstractButton>
Returns:


Copyright © 2010. All Rights Reserved.