Java Doc for WebBrowser.java in  » Testing » DDSteps » org » ddsteps » web » Java Source Code / Java DocumentationJava Source Code and Java Documentation

Java Source Code / Java Documentation
1. 6.0 JDK Core
2. 6.0 JDK Modules
3. 6.0 JDK Modules com.sun
4. 6.0 JDK Modules com.sun.java
5. 6.0 JDK Modules sun
6. 6.0 JDK Platform
7. Ajax
8. Apache Harmony Java SE
9. Aspect oriented
10. Authentication Authorization
11. Blogger System
12. Build
13. Byte Code
14. Cache
15. Chart
16. Chat
17. Code Analyzer
18. Collaboration
19. Content Management System
20. Database Client
21. Database DBMS
22. Database JDBC Connection Pool
23. Database ORM
24. Development
25. EJB Server geronimo
26. EJB Server GlassFish
27. EJB Server JBoss 4.2.1
28. EJB Server resin 3.1.5
29. ERP CRM Financial
30. ESB
31. Forum
32. GIS
33. Graphic Library
34. Groupware
35. HTML Parser
36. IDE
37. IDE Eclipse
38. IDE Netbeans
39. Installer
40. Internationalization Localization
41. Inversion of Control
42. Issue Tracking
43. J2EE
44. JBoss
45. JMS
46. JMX
47. Library
48. Mail Clients
49. Net
50. Parser
51. PDF
52. Portal
53. Profiler
54. Project Management
55. Report
56. RSS RDF
57. Rule Engine
58. Science
59. Scripting
60. Search Engine
61. Security
62. Sevlet Container
63. Source Control
64. Swing Library
65. Template Engine
66. Test Coverage
67. Testing
68. UML
69. Web Crawler
70. Web Framework
71. Web Mail
72. Web Server
73. Web Services
74. Web Services apache cxf 2.0.1
75. Web Services AXIS2
76. Wiki Engine
77. Workflow Engines
78. XML
79. XML UI
Java
Java Tutorial
Java Open Source
Jar File Download
Java Articles
Java Products
Java by API
Photoshop Tutorials
Maya Tutorials
Flash Tutorials
3ds-Max Tutorials
Illustrator Tutorials
GIMP Tutorials
C# / C Sharp
C# / CSharp Tutorial
C# / CSharp Open Source
ASP.Net
ASP.NET Tutorial
JavaScript DHTML
JavaScript Tutorial
JavaScript Reference
HTML / CSS
HTML CSS Reference
C / ANSI-C
C Tutorial
C++
C++ Tutorial
Ruby
PHP
Python
Python Tutorial
Python Open Source
SQL Server / T-SQL
SQL Server / T-SQL Tutorial
Oracle PL / SQL
Oracle PL/SQL Tutorial
PostgreSQL
SQL / MySQL
MySQL Tutorial
VB.Net
VB.Net Tutorial
Flash / Flex / ActionScript
VBA / Excel / Access / Word
XML
XML Tutorial
Microsoft Office PowerPoint 2007 Tutorial
Microsoft Office Excel 2007 Tutorial
Microsoft Office Word 2007 Tutorial
Java Source Code / Java Documentation » Testing » DDSteps » org.ddsteps.web 
Source Cross Reference  Class Diagram Java Document (Java Doc) 


org.ddsteps.web.WebBrowser

All known Subclasses:   org.ddsteps.web.jwebunit.JWebUnitWebBrowser,
WebBrowser
public interface WebBrowser (Code)
Interface for all toolkits that implement a stateful web browser.

This interface keeps the WebBrowser implementation and the teststeps that delegate to them in sync.

In 1.1 there is only (@link JWebUnitWebBrowser but soon we'll be adding Selenium too.
author:
   adamskogman





Method Summary
public  voidassertButtonDisabled(String buttonId)
     Assert that a button is present and disabled.
public  voidassertButtonEnabled(String buttonId)
     Assert that a button is present and enabled.
abstract public  voidassertButtonNotPresent(String buttonId)
     Assert that a button with a given id is not present.
abstract public  voidassertButtonPresent(String buttonId)
     Assert that a button with a given id is present.
abstract public  voidassertCheckboxNotSelected(String checkBoxName)
     Assert that a specific checkbox is not selected.
abstract public  voidassertCheckboxSelected(String checkBoxName)
     Assert that a specific checkbox is selected.
abstract public  voidassertCookiePresent(String cookieName)
     Checks to see if a cookie is present in the response.
abstract public  voidassertCookieValueEquals(String cookieName, String expectedValue)
     Assert the value of a cookie.
abstract public  voidassertElementNotPresent(String anID)
     Assert that an element with a given id is not present.
abstract public  voidassertElementPresent(String anID)
     Assert that an element with a given id is present.
abstract public  voidassertFormElementEmpty(String formElementName)
     Assert that a form element had no value / is empty.
abstract public  voidassertFormElementEquals(String formElementName, String expectedValue)
     Assert that a specific form element has an expected value.
abstract public  voidassertFormElementNotPresent(String formElementName)
     Assert that a form input element with a given name is not present.
public  voidassertFormElementNotPresentOrDisabled(String formElementName)
     Assert that a form element is not present or disabled.
abstract public  voidassertFormElementNotPresentWithLabel(String formElementLabel)
     Assert that a form input element with a given label is not present.
abstract public  voidassertFormElementPresent(String formElementName)
     Assert that a form input element with a given name is present.
public  voidassertFormElementPresentAndEnabled(String formElementName)
     Assert that a form element is present and enabled.
abstract public  voidassertFormElementPresentWithLabel(String formElementLabel)
     Assert that a form input element with a given label is present.
abstract public  voidassertFormNotPresent()
     Assert that there is not a form present.
abstract public  voidassertFormNotPresent(String nameOrID)
     Assert that there is not a form with the specified name or id present.
abstract public  voidassertFormPresent()
     Assert that there is a form present.
abstract public  voidassertFormPresent(String nameOrID)
     Assert that there is a form with the specified name or id present.
abstract public  voidassertFramePresent(String frameName)
     Assert that a frame with the given name is present.
abstract public  voidassertKeyInTable(String tableSummaryOrId, String key)
     Assert that the value of a given web resource is present in a specific table.
abstract public  voidassertKeyNotInTable(String tableSummaryOrId, String key)
     Assert that the value of a given web resource is not present in a specific table.
abstract public  voidassertKeyNotPresent(String key)
     Assert that a web resource's value is not present.
abstract public  voidassertKeyPresent(String key)
     Assert that a web resource's value is present.
abstract public  voidassertKeysInTable(String tableSummaryOrId, String[] keys)
     Assert that the values of a set of web resources are all present in a specific table.
abstract public  voidassertLinkNotPresent(String linkId)
     Assert that no link with the given id is present in the response.
abstract public  voidassertLinkNotPresentWithImage(String imageFileName)
     Assert that a link containing a specified image is not present.
abstract public  voidassertLinkNotPresentWithText(String linkText)
     Assert that no link containing the supplied text is present.
abstract public  voidassertLinkNotPresentWithText(String linkText, int index)
     Assert that no link containing the supplied text is present.
abstract public  voidassertLinkPresent(String linkId)
     Assert that a link with a given id is present in the response.
abstract public  voidassertLinkPresentWithImage(String imageFileName)
     Assert that a link containing a specified image is present.
abstract public  voidassertLinkPresentWithText(String linkText)
     Assert that a link containing the supplied text is present.
abstract public  voidassertLinkPresentWithText(String linkText, int index)
     Assert that a link containing the supplied text is present.
abstract public  voidassertOptionEquals(String selectName, String option)
     Assert that the currently selected display value of a select box matches a given value.
public  voidassertOptionIsSelectedByValue(String selectId, String selectedValue)
    
public  voidassertOptionValuePresent(String selectId, String value)
    
abstract public  voidassertOptionValuesEqual(String selectName, String[] expectedValues)
     Assert that the values of a select element's options match a given array of strings.
abstract public  voidassertOptionValuesNotEqual(String selectName, String[] optionValues)
     Assert that the values of a select element's options do not match a given array of strings.
abstract public  voidassertOptionsEqual(String selectName, String[] expectedOptions)
     Assert that the display values of a select element's options match a given array of strings.
abstract public  voidassertOptionsNotEqual(String selectName, String[] expectedOptions)
     Assert that the display values of a select element's options do not match a given array of strings.
abstract public  voidassertRadioOptionNotPresent(String name, String radioOption)
     Assert that a specific option is not present in a radio group.
abstract public  voidassertRadioOptionNotSelected(String name, String radioOption)
     Assert that a specific option is not selected in a radio group.
abstract public  voidassertRadioOptionPresent(String name, String radioOption)
     Assert that a specific option is present in a radio group.
abstract public  voidassertRadioOptionSelected(String name, String radioOption)
     Assert that a specific option is selected in a radio group.
abstract public  voidassertSubmitButtonNotPresent(String buttonName)
     Assert that a submit button with a given name is not present.
abstract public  voidassertSubmitButtonPresent(String buttonName)
     Assert that a submit button with a given name is present.
abstract public  voidassertSubmitButtonValue(String buttonName, String expectedValue)
     Assert that a submit button with a given name and value is present.
abstract public  voidassertTableEquals(String tableSummaryOrId, ExpectedTable expectedTable)
     Assert that a specific table matches an ExpectedTable.
abstract public  voidassertTableEquals(String tableSummaryOrId, String[][] expectedCellValues)
     Assert that a specific table matches a matrix of supplied text values.
abstract public  voidassertTableNotPresent(String tableSummaryOrId)
     Assert that a table with a given summary or id value is not present.
abstract public  voidassertTablePresent(String tableSummaryOrId)
     Assert that a table with a given summary or id value is present.
abstract public  voidassertTableRowsEqual(String tableSummaryOrId, int startRow, ExpectedTable expectedTable)
     Assert that a range of rows for a specific table matches a matrix of supplied text values.
abstract public  voidassertTableRowsEqual(String tableSummaryOrId, int startRow, String[][] expectedCellValues)
     Assert that a range of rows for a specific table matches a matrix of supplied text values.
abstract public  voidassertTextInElement(String elementID, String text)
     Assert that a given element contains specific text.
public  voidassertTextInElement(String elementId, String[] texts)
     If the list has any non blanks strings, the element must exist and have all the non blank strings in it.
abstract public  voidassertTextInTable(String tableSummaryOrId, String text)
     Assert that supplied text is present in a specific table.
abstract public  voidassertTextInTable(String tableSummaryOrId, String[] text)
     Assert that a set of text values are all present in a specific table.
abstract public  voidassertTextNotInElement(String elementID, String text)
     Assert that the given text is NOT in (contained in) the given element.
abstract public  voidassertTextNotInTable(String tableSummaryOrId, String text)
     Assert that supplied text is not present in a specific table.
abstract public  voidassertTextNotInTable(String tableSummaryOrId, String[] text)
     Assert that none of a set of text values are present in a specific table.
abstract public  voidassertTextNotPresent(String text)
     Assert that supplied text is not present.
abstract public  voidassertTextPresent(String text)
     Assert that supplied text is present.
abstract public  voidassertTitleEquals(String title)
     Assert title of current html page in conversation matches an expected value.
abstract public  voidassertTitleEqualsKey(String titleKey)
     Assert title of current html page matches the value of a specified web resource.
abstract public  voidassertWindowPresent(String windowName)
     Assert that a window with the given name is open.
abstract public  voidbeginAt(String relativeURL)
     Begin conversation at a url relative to the application root.
abstract public  voidcheckCheckbox(String checkBoxName)
     Select a specified checkbox.
abstract public  voidcheckCheckbox(String checkBoxName, String value)
     Check a checkbox and set a specific value.
abstract public  voidclickButton(String buttonId)
     Click the button with the given id.
abstract public  voidclickLink(String linkId)
     Navigate by selection of a link with given id.
abstract public  voidclickLinkWithImage(String imageFileName)
     Navigate by selection of a link with a given image.
abstract public  voidclickLinkWithText(String linkText)
     Navigate by selection of a link containing given text.
abstract public  voidclickLinkWithText(String linkText, int index)
     Navigate by selection of a link containing given text.
abstract public  voidclickLinkWithTextAfterText(String linkText, String labelText)
     Search for labelText in the document, then search forward until finding a link called linkText.
abstract public  voidendTrail()
     End a trail.
public  StringgetDefaultOption(String selectName)
     Gets the LABEL of the selected option in a select box.
abstract public  StringgetMessage(String key)
     Return the value of a web resource based on its key.
public  String[]getOptionValues(String selectId)
     Get all the option values for a select tag.
Parameters:
  selectId - The ID of the select tag.
public  StringgetSelectedOptionValue(String selectName)
     Gets the LABEL of the selected option in a select box.
Parameters:
  selectName - The NAME of the select tag.
abstract public  FilegetTrailFolder()
    
abstract public  voidgotoFrame(String frameName)
     Make the named frame active (current response will be frame's contents).
abstract public  voidgotoPage(String url)
     Goto a specific URL, regardless of the base URL.
abstract public  voidgotoRootWindow()
     Make the root window active.
abstract public  voidgotoWindow(String windowName)
     Make a given window active (current response will be window's contents).
abstract public  booleanisTrailEnabled()
    
abstract public  voidreset()
     Reset the current form.
abstract public  voidselectOption(String selectName, String option)
     Select an option with a given display value in a select element.
public  voidselectOptionByValue(String selectId, String value)
     Select an option using the value, not the key.
abstract public  voidsetFormElement(String formElementName, String value)
     Set the value of a form input element.
public  voidsetFormElement(String formElementName, String[] values)
     Overload to enable setting multiple form elements with the same name.
abstract public  voidsetTrailEnabled(boolean trailEnabled)
    
abstract public  voidsetTrailFolder(File trailFolder)
    
abstract public  voidsetUrl(String url)
     Set the base URL for the tested web application.
abstract public  voidsetWorkingForm(String nameOrId)
     Begin interaction with a specified form.
public  voidsetWorkingFormByFieldName(String fieldName)
     Finds the form with the specified field in, and sets that form as the working form.
public  voidsetWorkingFormByFieldNameAndValue(String fieldName, String value)
     Finds the form with the specified field in with a specific value, and sets that form as the working form.
abstract public  voidstartTrail(String trailName)
     Start a new trail.
abstract public  voidsubmit()
     Submit form - default submit button will be used (unnamed submit button, or named button if there is only one on the form.
abstract public  voidsubmit(String buttonName)
     Submit form by pressing named button.
public  voidsubmit(String buttonName, String value)
     Push a submit button based on the name and value of it.
abstract public  voiduncheckCheckbox(String checkBoxName)
     Deselect a specified checkbox.
abstract public  voiduncheckCheckbox(String checkBoxName, String value)
     Deselect a specified checkbox.
public  voidwritePage(String filename)
     Write the current page to a file, regardless of any current trail or if trailing is enabled or not.
abstract public  voidwriteTrail(String pageName)
     Your web test steps should call this to write suiteable pages to the trail.

If trailing is disabled (default) nothing will happen.
Parameters:
  pageName - A page name to prepend to the file name.




Method Detail
assertButtonDisabled
public void assertButtonDisabled(String buttonId)(Code)
Assert that a button is present and disabled.
Parameters:
  buttonId -



assertButtonEnabled
public void assertButtonEnabled(String buttonId)(Code)
Assert that a button is present and enabled.
Parameters:
  buttonId -



assertButtonNotPresent
abstract public void assertButtonNotPresent(String buttonId)(Code)
Assert that a button with a given id is not present.
Parameters:
  buttonId -



assertButtonPresent
abstract public void assertButtonPresent(String buttonId)(Code)
Assert that a button with a given id is present.
Parameters:
  buttonId -



assertCheckboxNotSelected
abstract public void assertCheckboxNotSelected(String checkBoxName)(Code)
Assert that a specific checkbox is not selected.
Parameters:
  checkBoxName -



assertCheckboxSelected
abstract public void assertCheckboxSelected(String checkBoxName)(Code)
Assert that a specific checkbox is selected.
Parameters:
  checkBoxName -



assertCookiePresent
abstract public void assertCookiePresent(String cookieName)(Code)
Checks to see if a cookie is present in the response. Contributed by Vivek Venugopalan.
Parameters:
  cookieName - The cookie name



assertCookieValueEquals
abstract public void assertCookieValueEquals(String cookieName, String expectedValue)(Code)
Assert the value of a cookie.
Parameters:
  cookieName -
Parameters:
  expectedValue -



assertElementNotPresent
abstract public void assertElementNotPresent(String anID)(Code)
Assert that an element with a given id is not present.
Parameters:
  anID - element id to test for.



assertElementPresent
abstract public void assertElementPresent(String anID)(Code)
Assert that an element with a given id is present.
Parameters:
  anID - element id to test for.



assertFormElementEmpty
abstract public void assertFormElementEmpty(String formElementName)(Code)
Assert that a form element had no value / is empty.
Parameters:
  formElementName -



assertFormElementEquals
abstract public void assertFormElementEquals(String formElementName, String expectedValue)(Code)
Assert that a specific form element has an expected value.
Parameters:
  formElementName -
Parameters:
  expectedValue -



assertFormElementNotPresent
abstract public void assertFormElementNotPresent(String formElementName)(Code)
Assert that a form input element with a given name is not present.
Parameters:
  formElementName -



assertFormElementNotPresentOrDisabled
public void assertFormElementNotPresentOrDisabled(String formElementName)(Code)
Assert that a form element is not present or disabled.
Parameters:
  formElementName - name of the form element



assertFormElementNotPresentWithLabel
abstract public void assertFormElementNotPresentWithLabel(String formElementLabel)(Code)
Assert that a form input element with a given label is not present.
Parameters:
  formElementLabel - label preceding form element.
See Also:   WebBrowser.setFormElementWithLabel(String,String)



assertFormElementPresent
abstract public void assertFormElementPresent(String formElementName)(Code)
Assert that a form input element with a given name is present.
Parameters:
  formElementName -



assertFormElementPresentAndEnabled
public void assertFormElementPresentAndEnabled(String formElementName)(Code)
Assert that a form element is present and enabled.
Parameters:
  formElementName - name of the form element



assertFormElementPresentWithLabel
abstract public void assertFormElementPresentWithLabel(String formElementLabel)(Code)
Assert that a form input element with a given label is present.
Parameters:
  formElementLabel - label preceding form element.
See Also:   WebBrowser.setFormElementWithLabel(String,String)



assertFormNotPresent
abstract public void assertFormNotPresent()(Code)
Assert that there is not a form present.



assertFormNotPresent
abstract public void assertFormNotPresent(String nameOrID)(Code)
Assert that there is not a form with the specified name or id present.
Parameters:
  nameOrID -



assertFormPresent
abstract public void assertFormPresent()(Code)
Assert that there is a form present.



assertFormPresent
abstract public void assertFormPresent(String nameOrID)(Code)
Assert that there is a form with the specified name or id present.
Parameters:
  nameOrID -



assertFramePresent
abstract public void assertFramePresent(String frameName)(Code)
Assert that a frame with the given name is present.
Parameters:
  frameName -



assertKeyInTable
abstract public void assertKeyInTable(String tableSummaryOrId, String key)(Code)
Assert that the value of a given web resource is present in a specific table.
Parameters:
  tableSummaryOrId - summary or id attribute value of table
Parameters:
  key - web resource name



assertKeyNotInTable
abstract public void assertKeyNotInTable(String tableSummaryOrId, String key)(Code)
Assert that the value of a given web resource is not present in a specific table.
Parameters:
  tableSummaryOrId - summary or id attribute value of table
Parameters:
  key - web resource name



assertKeyNotPresent
abstract public void assertKeyNotPresent(String key)(Code)
Assert that a web resource's value is not present.
Parameters:
  key - web resource name



assertKeyPresent
abstract public void assertKeyPresent(String key)(Code)
Assert that a web resource's value is present.
Parameters:
  key - web resource name



assertKeysInTable
abstract public void assertKeysInTable(String tableSummaryOrId, String[] keys)(Code)
Assert that the values of a set of web resources are all present in a specific table.
Parameters:
  tableSummaryOrId - summary or id attribute value of table
Parameters:
  keys - Array of web resource names.



assertLinkNotPresent
abstract public void assertLinkNotPresent(String linkId)(Code)
Assert that no link with the given id is present in the response.
Parameters:
  linkId -



assertLinkNotPresentWithImage
abstract public void assertLinkNotPresentWithImage(String imageFileName)(Code)
Assert that a link containing a specified image is not present.
Parameters:
  imageFileName - A suffix of the image's filename; for example, to match"images/my_icon.png", you could just pass in"my_icon.png".



assertLinkNotPresentWithText
abstract public void assertLinkNotPresentWithText(String linkText)(Code)
Assert that no link containing the supplied text is present.
Parameters:
  linkText -



assertLinkNotPresentWithText
abstract public void assertLinkNotPresentWithText(String linkText, int index)(Code)
Assert that no link containing the supplied text is present.
Parameters:
  linkText -
Parameters:
  index - The 0-based index, when more than one link with the same textis expected.



assertLinkPresent
abstract public void assertLinkPresent(String linkId)(Code)
Assert that a link with a given id is present in the response.
Parameters:
  linkId -



assertLinkPresentWithImage
abstract public void assertLinkPresentWithImage(String imageFileName)(Code)
Assert that a link containing a specified image is present.
Parameters:
  imageFileName - A suffix of the image's filename; for example, to match"images/my_icon.png", you could just pass in"my_icon.png".



assertLinkPresentWithText
abstract public void assertLinkPresentWithText(String linkText)(Code)
Assert that a link containing the supplied text is present.
Parameters:
  linkText -



assertLinkPresentWithText
abstract public void assertLinkPresentWithText(String linkText, int index)(Code)
Assert that a link containing the supplied text is present.
Parameters:
  linkText -
Parameters:
  index - The 0-based index, when more than one link with the same textis expected.



assertOptionEquals
abstract public void assertOptionEquals(String selectName, String option)(Code)
Assert that the currently selected display value of a select box matches a given value.
Parameters:
  selectName - name of the select element.
Parameters:
  option - expected display value of the selected option.



assertOptionIsSelectedByValue
public void assertOptionIsSelectedByValue(String selectId, String selectedValue)(Code)

Parameters:
  selectId - The select tag.
Parameters:
  selectedValue - The VALUE that should be selected.



assertOptionValuePresent
public void assertOptionValuePresent(String selectId, String value)(Code)

Parameters:
  selectId -
Parameters:
  value -



assertOptionValuesEqual
abstract public void assertOptionValuesEqual(String selectName, String[] expectedValues)(Code)
Assert that the values of a select element's options match a given array of strings.
Parameters:
  selectName - name of the select element.
Parameters:
  expectedValues - expected values for the select box.



assertOptionValuesNotEqual
abstract public void assertOptionValuesNotEqual(String selectName, String[] optionValues)(Code)
Assert that the values of a select element's options do not match a given array of strings.
Parameters:
  selectName - name of the select element.
Parameters:
  optionValues - expected values for the select box.



assertOptionsEqual
abstract public void assertOptionsEqual(String selectName, String[] expectedOptions)(Code)
Assert that the display values of a select element's options match a given array of strings.
Parameters:
  selectName - name of the select element.
Parameters:
  expectedOptions - expected display values for the select box, may be null.



assertOptionsNotEqual
abstract public void assertOptionsNotEqual(String selectName, String[] expectedOptions)(Code)
Assert that the display values of a select element's options do not match a given array of strings.
Parameters:
  selectName - name of the select element.
Parameters:
  expectedOptions - expected display values for the select box.



assertRadioOptionNotPresent
abstract public void assertRadioOptionNotPresent(String name, String radioOption)(Code)
Assert that a specific option is not present in a radio group.
Parameters:
  name - radio group name.
Parameters:
  radioOption - option to test for.



assertRadioOptionNotSelected
abstract public void assertRadioOptionNotSelected(String name, String radioOption)(Code)
Assert that a specific option is not selected in a radio group.
Parameters:
  name - radio group name.
Parameters:
  radioOption - option to test for selection.



assertRadioOptionPresent
abstract public void assertRadioOptionPresent(String name, String radioOption)(Code)
Assert that a specific option is present in a radio group.
Parameters:
  name - radio group name.
Parameters:
  radioOption - option to test for.



assertRadioOptionSelected
abstract public void assertRadioOptionSelected(String name, String radioOption)(Code)
Assert that a specific option is selected in a radio group.
Parameters:
  name - radio group name.
Parameters:
  radioOption - option to test for selection.



assertSubmitButtonNotPresent
abstract public void assertSubmitButtonNotPresent(String buttonName)(Code)
Assert that a submit button with a given name is not present.
Parameters:
  buttonName -



assertSubmitButtonPresent
abstract public void assertSubmitButtonPresent(String buttonName)(Code)
Assert that a submit button with a given name is present.
Parameters:
  buttonName -



assertSubmitButtonValue
abstract public void assertSubmitButtonValue(String buttonName, String expectedValue)(Code)
Assert that a submit button with a given name and value is present.
Parameters:
  buttonName -
Parameters:
  expectedValue -



assertTableEquals
abstract public void assertTableEquals(String tableSummaryOrId, ExpectedTable expectedTable)(Code)
Assert that a specific table matches an ExpectedTable.
Parameters:
  tableSummaryOrId - summary or id attribute value of table
Parameters:
  expectedTable - represents expected values (colspan supported).



assertTableEquals
abstract public void assertTableEquals(String tableSummaryOrId, String[][] expectedCellValues)(Code)
Assert that a specific table matches a matrix of supplied text values.
Parameters:
  tableSummaryOrId - summary or id attribute value of table
Parameters:
  expectedCellValues - double dimensional array of expected values



assertTableNotPresent
abstract public void assertTableNotPresent(String tableSummaryOrId)(Code)
Assert that a table with a given summary or id value is not present.
Parameters:
  tableSummaryOrId - summary or id attribute value of table



assertTablePresent
abstract public void assertTablePresent(String tableSummaryOrId)(Code)
Assert that a table with a given summary or id value is present.
Parameters:
  tableSummaryOrId - summary or id attribute value of table



assertTableRowsEqual
abstract public void assertTableRowsEqual(String tableSummaryOrId, int startRow, ExpectedTable expectedTable)(Code)
Assert that a range of rows for a specific table matches a matrix of supplied text values.
Parameters:
  tableSummaryOrId - summary or id attribute value of table
Parameters:
  startRow - index of start row for comparison
Parameters:
  expectedTable - represents expected values (colspan supported).



assertTableRowsEqual
abstract public void assertTableRowsEqual(String tableSummaryOrId, int startRow, String[][] expectedCellValues)(Code)
Assert that a range of rows for a specific table matches a matrix of supplied text values.
Parameters:
  tableSummaryOrId - summary or id attribute value of table
Parameters:
  startRow - index of start row for comparison
Parameters:
  expectedCellValues - double dimensional array of expected values



assertTextInElement
abstract public void assertTextInElement(String elementID, String text)(Code)
Assert that a given element contains specific text.
Parameters:
  elementID - id of element to be inspected.
Parameters:
  text - to check for.



assertTextInElement
public void assertTextInElement(String elementId, String[] texts)(Code)
If the list has any non blanks strings, the element must exist and have all the non blank strings in it.
Parameters:
  elementId -
Parameters:
  texts -



assertTextInTable
abstract public void assertTextInTable(String tableSummaryOrId, String text)(Code)
Assert that supplied text is present in a specific table.
Parameters:
  tableSummaryOrId - summary or id attribute value of table
Parameters:
  text -



assertTextInTable
abstract public void assertTextInTable(String tableSummaryOrId, String[] text)(Code)
Assert that a set of text values are all present in a specific table.
Parameters:
  tableSummaryOrId - summary or id attribute value of table
Parameters:
  text - Array of expected text values.



assertTextNotInElement
abstract public void assertTextNotInElement(String elementID, String text)(Code)
Assert that the given text is NOT in (contained in) the given element.
Parameters:
  elementID - Id of element
Parameters:
  text - The text to check for.



assertTextNotInTable
abstract public void assertTextNotInTable(String tableSummaryOrId, String text)(Code)
Assert that supplied text is not present in a specific table.
Parameters:
  tableSummaryOrId - summary or id attribute value of table
Parameters:
  text -



assertTextNotInTable
abstract public void assertTextNotInTable(String tableSummaryOrId, String[] text)(Code)
Assert that none of a set of text values are present in a specific table.
Parameters:
  tableSummaryOrId - summary or id attribute value of table
Parameters:
  text - Array of text values



assertTextNotPresent
abstract public void assertTextNotPresent(String text)(Code)
Assert that supplied text is not present.
Parameters:
  text -



assertTextPresent
abstract public void assertTextPresent(String text)(Code)
Assert that supplied text is present.
Parameters:
  text -



assertTitleEquals
abstract public void assertTitleEquals(String title)(Code)
Assert title of current html page in conversation matches an expected value.
Parameters:
  title - expected title value



assertTitleEqualsKey
abstract public void assertTitleEqualsKey(String titleKey)(Code)
Assert title of current html page matches the value of a specified web resource.
Parameters:
  titleKey - web resource key for title



assertWindowPresent
abstract public void assertWindowPresent(String windowName)(Code)
Assert that a window with the given name is open.
Parameters:
  windowName -



beginAt
abstract public void beginAt(String relativeURL)(Code)
Begin conversation at a url relative to the application root.
Parameters:
  relativeURL -



checkCheckbox
abstract public void checkCheckbox(String checkBoxName)(Code)
Select a specified checkbox.
Parameters:
  checkBoxName - name of checkbox to be deselected.



checkCheckbox
abstract public void checkCheckbox(String checkBoxName, String value)(Code)
Check a checkbox and set a specific value.
Parameters:
  checkBoxName -
Parameters:
  value -



clickButton
abstract public void clickButton(String buttonId)(Code)
Click the button with the given id.
Parameters:
  buttonId -



clickLink
abstract public void clickLink(String linkId)(Code)
Navigate by selection of a link with given id.
Parameters:
  linkId - id of link



clickLinkWithImage
abstract public void clickLinkWithImage(String imageFileName)(Code)
Navigate by selection of a link with a given image.
Parameters:
  imageFileName - A suffix of the image's filename; for example, to match"images/my_icon.png", you could just pass in"my_icon.png".



clickLinkWithText
abstract public void clickLinkWithText(String linkText)(Code)
Navigate by selection of a link containing given text.
Parameters:
  linkText -



clickLinkWithText
abstract public void clickLinkWithText(String linkText, int index)(Code)
Navigate by selection of a link containing given text.
Parameters:
  linkText -
Parameters:
  index - The 0-based index, when more than one link with the same textis expected.



clickLinkWithTextAfterText
abstract public void clickLinkWithTextAfterText(String linkText, String labelText)(Code)
Search for labelText in the document, then search forward until finding a link called linkText. Click it.
Parameters:
  linkText -
Parameters:
  labelText -



endTrail
abstract public void endTrail()(Code)
End a trail.



getDefaultOption
public String getDefaultOption(String selectName)(Code)
Gets the LABEL of the selected option in a select box.
Parameters:
  selectName - The label



getMessage
abstract public String getMessage(String key)(Code)
Return the value of a web resource based on its key. This translates to a property file lookup with the locale based on the current TestContext.
Parameters:
  key - name of the web resource. value of the web resource, encoded according to TestContext.



getOptionValues
public String[] getOptionValues(String selectId)(Code)
Get all the option values for a select tag.
Parameters:
  selectId - The ID of the select tag. Array of options.



getSelectedOptionValue
public String getSelectedOptionValue(String selectName)(Code)
Gets the LABEL of the selected option in a select box.
Parameters:
  selectName - The NAME of the select tag. The label



getTrailFolder
abstract public File getTrailFolder()(Code)
Returns the trailFolder.



gotoFrame
abstract public void gotoFrame(String frameName)(Code)
Make the named frame active (current response will be frame's contents).
Parameters:
  frameName -



gotoPage
abstract public void gotoPage(String url)(Code)
Goto a specific URL, regardless of the base URL.
Parameters:
  url - The URL.



gotoRootWindow
abstract public void gotoRootWindow()(Code)
Make the root window active.



gotoWindow
abstract public void gotoWindow(String windowName)(Code)
Make a given window active (current response will be window's contents).
Parameters:
  windowName -



isTrailEnabled
abstract public boolean isTrailEnabled()(Code)
Returns the trailEnabled.



reset
abstract public void reset()(Code)
Reset the current form.



selectOption
abstract public void selectOption(String selectName, String option)(Code)
Select an option with a given display value in a select element.
Parameters:
  selectName - name of select element.
Parameters:
  option - display value of option to be selected.



selectOptionByValue
public void selectOptionByValue(String selectId, String value)(Code)
Select an option using the value, not the key.
Parameters:
  selectId - The id of the select tag.
Parameters:
  value - The value



setFormElement
abstract public void setFormElement(String formElementName, String value)(Code)
Set the value of a form input element.
Parameters:
  formElementName - name of form element.
Parameters:
  value -



setFormElement
public void setFormElement(String formElementName, String[] values)(Code)
Overload to enable setting multiple form elements with the same name.
Parameters:
  formElementName - name of the form element
Parameters:
  values - the values to set



setTrailEnabled
abstract public void setTrailEnabled(boolean trailEnabled)(Code)

Parameters:
  trailEnabled - The trailEnabled to set.



setTrailFolder
abstract public void setTrailFolder(File trailFolder)(Code)

Parameters:
  trailFolder - The trailFolder to set.



setUrl
abstract public void setUrl(String url)(Code)
Set the base URL for the tested web application.

Delegate method - sets the baseUrl on the test context.
Parameters:
  url - The base url, typically the context url of your webapplication.




setWorkingForm
abstract public void setWorkingForm(String nameOrId)(Code)
Begin interaction with a specified form. If form interaction methods are called without explicitly calling this method first, jWebUnit will attempt to determine itself which form is being manipulated. It is not necessary to call this method if their is only one form on the current page.
Parameters:
  nameOrId - name or id of the form to work with.



setWorkingFormByFieldName
public void setWorkingFormByFieldName(String fieldName)(Code)
Finds the form with the specified field in, and sets that form as the working form. The form does not need to have a name or id.

This method does use a bit of evil reflection magic to force itself on HttpUnit, so you really should concider adding a name or id to your form.

Fails if there are more than one form with that parameter.
Parameters:
  fieldName - The field name




setWorkingFormByFieldNameAndValue
public void setWorkingFormByFieldNameAndValue(String fieldName, String value)(Code)
Finds the form with the specified field in with a specific value, and sets that form as the working form. The form does not need to have a name or id. Very useful for choosing between many different forms that differ only by the value of a hidden field.

This method does use a bit of evil reflection magic to force itself on HttpUnit, so you really should concider adding a name or id to your form.

It will use the FIRST form it finds with the requested combo.
Parameters:
  fieldName - The field name
Parameters:
  value - The field value




startTrail
abstract public void startTrail(String trailName)(Code)
Start a new trail. If you start a new trail without ending the last one, a new trail will be started with no problems.
Parameters:
  trailName - Typically the test case name.



submit
abstract public void submit()(Code)
Submit form - default submit button will be used (unnamed submit button, or named button if there is only one on the form.



submit
abstract public void submit(String buttonName)(Code)
Submit form by pressing named button.
Parameters:
  buttonName - name of button to submit form with.



submit
public void submit(String buttonName, String value)(Code)
Push a submit button based on the name and value of it.
Parameters:
  buttonName -
Parameters:
  value -



uncheckCheckbox
abstract public void uncheckCheckbox(String checkBoxName)(Code)
Deselect a specified checkbox.
Parameters:
  checkBoxName - name of checkbox to be deselected.



uncheckCheckbox
abstract public void uncheckCheckbox(String checkBoxName, String value)(Code)
Deselect a specified checkbox. Sets the value.
Parameters:
  checkBoxName -
Parameters:
  value -



writePage
public void writePage(String filename)(Code)
Write the current page to a file, regardless of any current trail or if trailing is enabled or not.

If you want a full trail of everything the test sees, use the trail functionality instead.
Parameters:
  filename - Relative filename in the trail folder, or a full file name.




writeTrail
abstract public void writeTrail(String pageName)(Code)
Your web test steps should call this to write suiteable pages to the trail.

If trailing is disabled (default) nothing will happen.
Parameters:
  pageName - A page name to prepend to the file name. Useful for the enduser to find out what is happening.




www.java2java.com | Contact Us
Copyright 2009 - 12 Demo Source and Support. All rights reserved.
All other trademarks are property of their respective owners.