com.gargoylesoftware.htmlunit.html
Class ClickableElementTest

java.lang.Object
  extended by com.gargoylesoftware.htmlunit.WebTestCase
      extended by com.gargoylesoftware.htmlunit.SimpleWebTestCase
          extended by com.gargoylesoftware.htmlunit.html.ClickableElementTest

public class ClickableElementTest
extends SimpleWebTestCase

Tests for various clickable elements.

Version:
$Revision: 7931 $
Author:
David K. Taylor, Chris Erskine, Marc Guillemot, Ahmed Ashour

Field Summary
 
Fields inherited from class com.gargoylesoftware.htmlunit.WebTestCase
DEFAULT_WAIT_TIME, DEFAULT_WAIT_TIME_FACTOR, FLAG_ALL_BROWSERS, generateTest_browserVersion_, GEOLOCATION_IGNORE, JAVASCRIPT_MIME_TYPE, LINE_SEPARATOR, PORT, PORT2, PORT3, PROPERTY_GENERATE_TESTPAGES, SOCKS_PROXY_HOST, SOCKS_PROXY_PORT, SOCKS_PROXY_SKIP, URL_CROSS_ORIGIN, URL_CROSS_ORIGIN_BASE, URL_CROSS_ORIGIN2, URL_FIRST, URL_SECOND, URL_THIRD
 
Constructor Summary
ClickableElementTest()
           
 
Method Summary
 void abbreviation_onClick()
          Test onClick handler and click method of abbreviation element.
 void acronym_onClick()
          Test onClick handler and click method of acronym element.
 void address_onClick()
          Test onClick handler and click method of address element.
 void anchor_onClick()
          Test onClick handler and click method of anchor element.
 void area_onClick()
          Test onClick handler and click method of area element.
 void big_onClick()
          Test onClick handler and click method of big element.
 void blockquote_onClick()
          Test onClick handler and click method of blockquote element.
 void body_onClick()
          Test onClick handler and click method of body element.
 void bold_onClick()
          Test onClick handler and click method of bold element.
 void button_onClick()
          Test onClick handler and click method of button element.
 void button_onClickTwice()
          Test onClick handler can be called multiple times.
 void center_onClick()
          Test onClick handler and click method of center element.
 void checkbox_onClickUpdatesStateFirst()
           
 void cite_onClick()
          Test onClick handler and click method of cite element.
 void code_onClick()
          Test onClick handler and click method of code element.
 void dblClick()
           
 void definition_onClick()
          Test onClick handler and click method of definition element.
 void definitionDescription_onClick()
          Test onClick handler and click method of definition description dd element.
 void definitionList_onClick()
          Test onClick handler and click method of definition list dl element.
 void definitionTerm_onClick()
          Test onClick handler and click method of definition term dt element.
 void deletedText_onClick()
          Test onClick handler and click method of deleted text element.
 void directory_onClick()
          Test onClick handler and click method of directory element.
 void division_onClick()
          Test onClick handler and click method of division element.
 void emphasis_onClick()
          Test onClick handler and click method of emphasis element.
 void fieldSet_onClick()
          Test onClick handler and click method of field set element.
 void form_onClick()
          Test onClick handler and click method of form element.
 void header1_onClick()
          Test onClick handler and click method of header1 element.
 void header2_onClick()
          Test onClick handler and click method of header2 element.
 void header3_onClick()
          Test onClick handler and click method of header3 element.
 void header4_onClick()
          Test onClick handler and click method of header4 element.
 void header5_onClick()
          Test onClick handler and click method of header5 element.
 void header6_onClick()
          Test onClick handler and click method of header6 element.
 void horizontalRule_onClick()
          Test onClick handler and click method of horizontal rule element.
 void image_onClick()
          Test onClick handler and click method of image element.
 void input_onClick()
          Test onClick handler and click method of input element.
 void insertedText_onClick()
          Test onClick handler and click method of inserted text element.
 void italics_onClick()
          Test onClick handler and click method of italics element.
 void javaScriptError_onClick()
          Test that no NPE is thrown when JS fails on link click and WebClient.setThrowExceptionOnScriptError(false) is used.
 void keyboard_onClick()
          Test onClick handler and click method of keyboard element.
 void label_onClick()
          Test onClick handler and click method of label element.
 void legend_onClick()
          Test onClick handler and click method of legend element.
 void link_onClick()
          Test onClick handler and click method of link element.
 void listItem_onClick()
          Test onClick handler and click method of List Item element.
 void map_onClick()
          Test onClick handler and click method of map element.
 void menu_onClick()
          Test onClick handler and click method of menu element.
 void noFrames_onClick()
          Test onClick handler and click method of no frames element.
 void noScript_onClick()
          Test onClick handler and click method of no script element.
 void object_onClick()
          Test onClick handler and click method of object element.
 void option_onClick()
          Test onClick handler and click method of option element.
 void optionGroup_onClick()
          Test onClick handler and click method of Option Group element.
 void orderedList_onClick()
          Test onClick handler and click method of Ordered List element.
 void paragraph_onClick()
          Test onClick handler and click method of paragraph element.
 void pre_onClick()
          Test onClick handler and click method of pre element.
 void quotation_onClick()
          Test onClick handler and click method of inline Quotation element.
 void sample_onClick()
          Test onClick handler and click method of sample element.
 void select_onClick()
          Test onClick handler and click method of select element.
 void setOnClick()
          Test setting onClick handler from inside the onClick handler.
 void small_onClick()
          Test onClick handler and click method of small element.
 void span_onClick()
          Test onClick handler and click method of span element.
 void strike_onClick()
          Test onClick handler and click method of strike element.
 void strikethrough_onClick()
          Test onClick handler and click method of strikethrough element.
 void subscript_onClick()
          Test onClick handler and click method of subscript element.
 void superscript_onClick()
          Test onClick handler and click method of superscript element.
 void table_onClick()
          Test onClick handler and click method of table element.
 void tableBody_onClick()
          Test onClick handler and click method of table body element.
 void tableCaption_onClick()
          Test onClick handler and click method of table caption element.
 void tableColumn_onClick()
          Test onClick handler and click method of table column element.
 void tableColumnGroup_onClick()
          Test onClick handler and click method of table column group element.
 void tableDataCell_onClick()
          Test onClick handler and click method of table data cell element.
 void tableFooter_onClick()
          Test onClick handler and click method of table footer element.
 void tableHeader_onClick()
          Test onClick handler and click method of table header element.
 void tableHeaderCell_onClick()
          Test onClick handler and click method of table header cell element.
 void tableRow_onClick()
          Test onClick handler and click method of table row element.
 void tableRow_onClickSetByNestedScript()
          Test when HtmlTableRow.onclick is set by a JavaScript.
 void tableRow_onClickSetOnLoad()
          Test when HtmlTableRow.onclick is set by JavaScript.
 void teletype_onClick()
          Test onClick handler and click method of teletype element.
 void textarea_onClick()
          Test onClick handler and click method of textarea element.
 void underline_onClick()
          Test onClick handler and click method of underline element.
 void unorderedList_onClick()
          Test onClick handler and click method of unordered List element.
 void variable_onClick()
          Test onClick handler and click method of variable element.
 
Methods inherited from class com.gargoylesoftware.htmlunit.SimpleWebTestCase
createNewWebClient, getJavaScriptThreads, getMockConnection, getWebClient, getWebClientWithMockWebConnection, loadPage, loadPage, loadPage, loadPage, loadPage, loadPage, loadPage, loadPageWithAlerts, loadPageWithAlerts, loadUrl, readJSThreadsBeforeTest, releaseResources, testHTMLFile
 
Methods inherited from class com.gargoylesoftware.htmlunit.WebTestCase
assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertFalse, assertNull, assertTrue, assertTrue, clone, createTestPageForRealBrowserIfNeeded, createTestPageForRealBrowserIfNeeded, expandExpectedAlertsVariables, generateTestForWebDriver, getBrowserVersion, getDefaultUrl, getExpectedAlerts, getFileAsStream, getFileObject, getMockWebConnection, getModifiedContent, loadExpectation, setExpectedAlerts, setGenerateTest_notYetImplemented, setMockWebConnection
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ClickableElementTest

public ClickableElementTest()
Method Detail

anchor_onClick

public void anchor_onClick()
                    throws Exception
Test onClick handler and click method of anchor element.

Throws:
Exception - if the test fails

abbreviation_onClick

public void abbreviation_onClick()
                          throws Exception
Test onClick handler and click method of abbreviation element.

Throws:
Exception - if the test fails

acronym_onClick

public void acronym_onClick()
                     throws Exception
Test onClick handler and click method of acronym element.

Throws:
Exception - if the test fails

address_onClick

public void address_onClick()
                     throws Exception
Test onClick handler and click method of address element.

Throws:
Exception - if the test fails

area_onClick

public void area_onClick()
                  throws Exception
Test onClick handler and click method of area element.

Throws:
Exception - if the test fails

bold_onClick

public void bold_onClick()
                  throws Exception
Test onClick handler and click method of bold element.

Throws:
Exception - if the test fails

big_onClick

public void big_onClick()
                 throws Exception
Test onClick handler and click method of big element.

Throws:
Exception - if the test fails

blockquote_onClick

public void blockquote_onClick()
                        throws Exception
Test onClick handler and click method of blockquote element.

Throws:
Exception - if the test fails

body_onClick

public void body_onClick()
                  throws Exception
Test onClick handler and click method of body element.

Throws:
Exception - if the test fails

button_onClick

public void button_onClick()
                    throws Exception
Test onClick handler and click method of button element.

Throws:
Exception - if the test fails

button_onClickTwice

public void button_onClickTwice()
                         throws Exception
Test onClick handler can be called multiple times.

Throws:
Exception - if the test fails

cite_onClick

public void cite_onClick()
                  throws Exception
Test onClick handler and click method of cite element.

Throws:
Exception - if the test fails

code_onClick

public void code_onClick()
                  throws Exception
Test onClick handler and click method of code element.

Throws:
Exception - if the test fails

tableColumn_onClick

public void tableColumn_onClick()
                         throws Exception
Test onClick handler and click method of table column element.

Throws:
Exception - if the test fails

tableColumnGroup_onClick

public void tableColumnGroup_onClick()
                              throws Exception
Test onClick handler and click method of table column group element.

Throws:
Exception - if the test fails

center_onClick

public void center_onClick()
                    throws Exception
Test onClick handler and click method of center element.

Throws:
Exception - if the test fails

tableCaption_onClick

public void tableCaption_onClick()
                          throws Exception
Test onClick handler and click method of table caption element.

Throws:
Exception - if the test fails

definitionDescription_onClick

public void definitionDescription_onClick()
                                   throws Exception
Test onClick handler and click method of definition description dd element.

Throws:
Exception - if the test fails

javaScriptError_onClick

public void javaScriptError_onClick()
                             throws Exception
Test that no NPE is thrown when JS fails on link click and WebClient.setThrowExceptionOnScriptError(false) is used. Test for bug 1385864.

Throws:
Exception - if the test fails

definition_onClick

public void definition_onClick()
                        throws Exception
Test onClick handler and click method of definition element.

Throws:
Exception - if the test fails

directory_onClick

public void directory_onClick()
                       throws Exception
Test onClick handler and click method of directory element.

Throws:
Exception - if the test fails

definitionList_onClick

public void definitionList_onClick()
                            throws Exception
Test onClick handler and click method of definition list dl element.

Throws:
Exception - if the test fails

definitionTerm_onClick

public void definitionTerm_onClick()
                            throws Exception
Test onClick handler and click method of definition term dt element.

Throws:
Exception - if the test fails

deletedText_onClick

public void deletedText_onClick()
                         throws Exception
Test onClick handler and click method of deleted text element.

Throws:
Exception - if the test fails

division_onClick

public void division_onClick()
                      throws Exception
Test onClick handler and click method of division element.

Throws:
Exception - if the test fails

emphasis_onClick

public void emphasis_onClick()
                      throws Exception
Test onClick handler and click method of emphasis element.

Throws:
Exception - if the test fails

fieldSet_onClick

public void fieldSet_onClick()
                      throws Exception
Test onClick handler and click method of field set element.

Throws:
Exception - if the test fails

form_onClick

public void form_onClick()
                  throws Exception
Test onClick handler and click method of form element.

Throws:
Exception - if the test fails

italics_onClick

public void italics_onClick()
                     throws Exception
Test onClick handler and click method of italics element.

Throws:
Exception - if the test fails

image_onClick

public void image_onClick()
                   throws Exception
Test onClick handler and click method of image element.

Throws:
Exception - if the test fails

header1_onClick

public void header1_onClick()
                     throws Exception
Test onClick handler and click method of header1 element.

Throws:
Exception - if the test fails

header2_onClick

public void header2_onClick()
                     throws Exception
Test onClick handler and click method of header2 element.

Throws:
Exception - if the test fails

header3_onClick

public void header3_onClick()
                     throws Exception
Test onClick handler and click method of header3 element.

Throws:
Exception - if the test fails

header4_onClick

public void header4_onClick()
                     throws Exception
Test onClick handler and click method of header4 element.

Throws:
Exception - if the test fails

header5_onClick

public void header5_onClick()
                     throws Exception
Test onClick handler and click method of header5 element.

Throws:
Exception - if the test fails

header6_onClick

public void header6_onClick()
                     throws Exception
Test onClick handler and click method of header6 element.

Throws:
Exception - if the test fails

horizontalRule_onClick

public void horizontalRule_onClick()
                            throws Exception
Test onClick handler and click method of horizontal rule element.

Throws:
Exception - if the test fails

input_onClick

public void input_onClick()
                   throws Exception
Test onClick handler and click method of input element.

Throws:
Exception - if the test fails

insertedText_onClick

public void insertedText_onClick()
                          throws Exception
Test onClick handler and click method of inserted text element.

Throws:
Exception - if the test fails

keyboard_onClick

public void keyboard_onClick()
                      throws Exception
Test onClick handler and click method of keyboard element.

Throws:
Exception - if the test fails

label_onClick

public void label_onClick()
                   throws Exception
Test onClick handler and click method of label element.

Throws:
Exception - if the test fails

legend_onClick

public void legend_onClick()
                    throws Exception
Test onClick handler and click method of legend element.

Throws:
Exception - if the test fails

link_onClick

public void link_onClick()
                  throws Exception
Test onClick handler and click method of link element.

Throws:
Exception - if the test fails

listItem_onClick

public void listItem_onClick()
                      throws Exception
Test onClick handler and click method of List Item element.

Throws:
Exception - if the test fails

map_onClick

public void map_onClick()
                 throws Exception
Test onClick handler and click method of map element.

Throws:
Exception - if the test fails

menu_onClick

public void menu_onClick()
                  throws Exception
Test onClick handler and click method of menu element.

Throws:
Exception - if the test fails

noFrames_onClick

public void noFrames_onClick()
                      throws Exception
Test onClick handler and click method of no frames element.

Throws:
Exception - if the test fails

noScript_onClick

public void noScript_onClick()
                      throws Exception
Test onClick handler and click method of no script element.

Throws:
Exception - if the test fails

object_onClick

public void object_onClick()
                    throws Exception
Test onClick handler and click method of object element.

Throws:
Exception - if the test fails

option_onClick

public void option_onClick()
                    throws Exception
Test onClick handler and click method of option element.

Throws:
Exception - if the test fails

optionGroup_onClick

public void optionGroup_onClick()
                         throws Exception
Test onClick handler and click method of Option Group element.

Throws:
Exception - if the test fails

orderedList_onClick

public void orderedList_onClick()
                         throws Exception
Test onClick handler and click method of Ordered List element.

Throws:
Exception - if the test fails

paragraph_onClick

public void paragraph_onClick()
                       throws Exception
Test onClick handler and click method of paragraph element.

Throws:
Exception - if the test fails

pre_onClick

public void pre_onClick()
                 throws Exception
Test onClick handler and click method of pre element.

Throws:
Exception - if the test fails

quotation_onClick

public void quotation_onClick()
                       throws Exception
Test onClick handler and click method of inline Quotation element.

Throws:
Exception - if the test fails

strikethrough_onClick

public void strikethrough_onClick()
                           throws Exception
Test onClick handler and click method of strikethrough element.

Throws:
Exception - if the test fails

sample_onClick

public void sample_onClick()
                    throws Exception
Test onClick handler and click method of sample element.

Throws:
Exception - if the test fails

select_onClick

public void select_onClick()
                    throws Exception
Test onClick handler and click method of select element.

Throws:
Exception - if the test fails

small_onClick

public void small_onClick()
                   throws Exception
Test onClick handler and click method of small element.

Throws:
Exception - if the test fails

span_onClick

public void span_onClick()
                  throws Exception
Test onClick handler and click method of span element.

Throws:
Exception - if the test fails

strike_onClick

public void strike_onClick()
                    throws Exception
Test onClick handler and click method of strike element.

Throws:
Exception - if the test fails

subscript_onClick

public void subscript_onClick()
                       throws Exception
Test onClick handler and click method of subscript element.

Throws:
Exception - if the test fails

superscript_onClick

public void superscript_onClick()
                         throws Exception
Test onClick handler and click method of superscript element.

Throws:
Exception - if the test fails

table_onClick

public void table_onClick()
                   throws Exception
Test onClick handler and click method of table element.

Throws:
Exception - if the test fails

tableBody_onClick

public void tableBody_onClick()
                       throws Exception
Test onClick handler and click method of table body element.

Throws:
Exception - if the test fails

tableDataCell_onClick

public void tableDataCell_onClick()
                           throws Exception
Test onClick handler and click method of table data cell element.

Throws:
Exception - if the test fails

textarea_onClick

public void textarea_onClick()
                      throws Exception
Test onClick handler and click method of textarea element.

Throws:
Exception - if the test fails

tableFooter_onClick

public void tableFooter_onClick()
                         throws Exception
Test onClick handler and click method of table footer element.

Throws:
Exception - if the test fails

tableHeaderCell_onClick

public void tableHeaderCell_onClick()
                             throws Exception
Test onClick handler and click method of table header cell element.

Throws:
Exception - if the test fails

tableHeader_onClick

public void tableHeader_onClick()
                         throws Exception
Test onClick handler and click method of table header element.

Throws:
Exception - if the test fails

tableRow_onClick

public void tableRow_onClick()
                      throws Exception
Test onClick handler and click method of table row element.

Throws:
Exception - if the test fails

tableRow_onClickSetOnLoad

public void tableRow_onClickSetOnLoad()
                               throws Exception
Test when HtmlTableRow.onclick is set by JavaScript.

Throws:
Exception - if the test fails

checkbox_onClickUpdatesStateFirst

public void checkbox_onClickUpdatesStateFirst()
                                       throws Exception
Throws:
Exception - if the test fails

tableRow_onClickSetByNestedScript

public void tableRow_onClickSetByNestedScript()
                                       throws Exception
Test when HtmlTableRow.onclick is set by a JavaScript.

Throws:
Exception - if the test fails

teletype_onClick

public void teletype_onClick()
                      throws Exception
Test onClick handler and click method of teletype element.

Throws:
Exception - if the test fails

underline_onClick

public void underline_onClick()
                       throws Exception
Test onClick handler and click method of underline element.

Throws:
Exception - if the test fails

unorderedList_onClick

public void unorderedList_onClick()
                           throws Exception
Test onClick handler and click method of unordered List element.

Throws:
Exception - if the test fails

variable_onClick

public void variable_onClick()
                      throws Exception
Test onClick handler and click method of variable element.

Throws:
Exception - if the test fails

setOnClick

public void setOnClick()
                throws Exception
Test setting onClick handler from inside the onClick handler.

Throws:
Exception - if the test fails

dblClick

public void dblClick()
              throws Exception
Throws:
Exception - if the test fails


Copyright © 2002-2013 Gargoyle Software Inc.. All Rights Reserved.