Revision: 647
          http://svn.sourceforge.net/jwebunit/?rev=647&view=rev
Author:   henryju
Date:     2007-01-02 06:59:26 -0800 (Tue, 02 Jan 2007)

Log Message:
-----------
Add new test for image input button.

Modified Paths:
--------------
    
branches/1.x/jwebunit-commons-tests/src/main/java/net/sourceforge/jwebunit/tests/FormSubmissionTest.java

Modified: 
branches/1.x/jwebunit-commons-tests/src/main/java/net/sourceforge/jwebunit/tests/FormSubmissionTest.java
===================================================================
--- 
branches/1.x/jwebunit-commons-tests/src/main/java/net/sourceforge/jwebunit/tests/FormSubmissionTest.java
    2007-01-02 14:57:39 UTC (rev 646)
+++ 
branches/1.x/jwebunit-commons-tests/src/main/java/net/sourceforge/jwebunit/tests/FormSubmissionTest.java
    2007-01-02 14:59:26 UTC (rev 647)
@@ -83,11 +83,21 @@
     public void testSubmitImageInput() {
         beginAt("/InputImageForm.html");
         setTextField("color", "toto");
-        clickElementByXPath("//[EMAIL PROTECTED]'image' and @name='image']");
+        assertSubmitButtonPresent();
+        submit();
         assertTextPresent("Submitted parameters");
         assertTextPresent("color=toto");
     }
 
+    public void testSubmitImageInputByName() {
+        beginAt("/InputImageForm.html");
+        setTextField("color", "toto");
+        assertSubmitButtonPresent("image");
+        submit("image");
+        assertTextPresent("Submitted parameters");
+        assertTextPresent("color=toto");
+    }
+
     public void testCheckBoxSelection() {
         beginAt("/SingleNamedButtonForm.html");
         checkCheckbox("checkBox");


This was sent by the SourceForge.net collaborative development platform, the 
world's largest Open Source development site.

-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys - and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
_______________________________________________
Jwebunit-development mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/jwebunit-development

Reply via email to