jwebunit-development Mailing List for JWebUnit (Page 10)
Brought to you by:
henryju
You can subscribe to this list here.
| 2004 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
(98) |
Jul
(45) |
Aug
(49) |
Sep
(90) |
Oct
(28) |
Nov
(18) |
Dec
(17) |
|---|---|---|---|---|---|---|---|---|---|---|---|---|
| 2005 |
Jan
(14) |
Feb
(21) |
Mar
(52) |
Apr
(39) |
May
(61) |
Jun
(35) |
Jul
(42) |
Aug
(31) |
Sep
(34) |
Oct
(16) |
Nov
(14) |
Dec
(61) |
| 2006 |
Jan
(39) |
Feb
(11) |
Mar
(29) |
Apr
(29) |
May
(30) |
Jun
(145) |
Jul
(61) |
Aug
(40) |
Sep
(36) |
Oct
(66) |
Nov
(50) |
Dec
(11) |
| 2007 |
Jan
(30) |
Feb
(1) |
Mar
(47) |
Apr
(9) |
May
(36) |
Jun
(13) |
Jul
(7) |
Aug
(5) |
Sep
(6) |
Oct
(3) |
Nov
(11) |
Dec
(36) |
| 2008 |
Jan
(12) |
Feb
|
Mar
(4) |
Apr
(29) |
May
(1) |
Jun
(8) |
Jul
(10) |
Aug
|
Sep
(2) |
Oct
(77) |
Nov
(107) |
Dec
(46) |
| 2009 |
Jan
(17) |
Feb
(13) |
Mar
(27) |
Apr
(5) |
May
(8) |
Jun
(17) |
Jul
(10) |
Aug
(25) |
Sep
(15) |
Oct
(4) |
Nov
(4) |
Dec
(10) |
| 2010 |
Jan
|
Feb
(6) |
Mar
(12) |
Apr
(15) |
May
(4) |
Jun
(5) |
Jul
(9) |
Aug
(5) |
Sep
(5) |
Oct
(63) |
Nov
(9) |
Dec
(1) |
| 2011 |
Jan
(9) |
Feb
(3) |
Mar
(15) |
Apr
|
May
|
Jun
(3) |
Jul
|
Aug
(14) |
Sep
(15) |
Oct
(11) |
Nov
(1) |
Dec
(2) |
| 2012 |
Jan
(6) |
Feb
(1) |
Mar
|
Apr
|
May
|
Jun
|
Jul
(14) |
Aug
(17) |
Sep
(8) |
Oct
(1) |
Nov
(17) |
Dec
|
| 2014 |
Jan
|
Feb
|
Mar
(13) |
Apr
|
May
(1) |
Jun
|
Jul
|
Aug
|
Sep
|
Oct
(3) |
Nov
|
Dec
|
| 2015 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
(2) |
Jul
(13) |
Aug
|
Sep
|
Oct
(4) |
Nov
|
Dec
|
|
From: <he...@us...> - 2010-10-19 09:30:58
|
Revision: 862
http://jwebunit.svn.sourceforge.net/jwebunit/?rev=862&view=rev
Author: henryju
Date: 2010-10-19 09:30:51 +0000 (Tue, 19 Oct 2010)
Log Message:
-----------
Added reference to SF issue.
Modified Paths:
--------------
trunk/src/changes/changes.xml
Modified: trunk/src/changes/changes.xml
===================================================================
--- trunk/src/changes/changes.xml 2010-10-18 16:02:25 UTC (rev 861)
+++ trunk/src/changes/changes.xml 2010-10-19 09:30:51 UTC (rev 862)
@@ -32,7 +32,7 @@
</properties>
<body>
<release version="3.0" date="UNKNOW" description="Updated all internals to JUnit 4">
- <action type="update" dev="henryju">
+ <action type="update" dev="henryju" issue="2837745">
Updated to JUnit 4. See migration section of the documentation.
</action>
</release>
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: SourceForge.net <no...@so...> - 2010-10-19 09:29:23
|
Feature Requests item #2837745, was opened at 2009-08-14 18:14 Message generated for change (Settings changed) made by henryju You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=497985&aid=2837745&group_id=61302 Please note that this message will contain a full copy of the comment thread, including the initial issue submission, for this request, not just the latest update. Category: Core API >Group: Release 3.0 Status: Open Priority: 5 Private: No Submitted By: Clint Kim (kimson1st) >Assigned to: Julien HENRY (henryju) Summary: Add explicit support for JUnit 4 Initial Comment: It seems all the assertions were made using JUnit 3.x framework. JWebUnit should support JUnit 4 assertions (org.junit.Assert.*). Maybe create WebTesterJUnit4 class? Thanks. ---------------------------------------------------------------------- You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=497985&aid=2837745&group_id=61302 |
|
From: <he...@us...> - 2010-10-18 16:02:31
|
Revision: 861
http://jwebunit.svn.sourceforge.net/jwebunit/?rev=861&view=rev
Author: henryju
Date: 2010-10-18 16:02:25 +0000 (Mon, 18 Oct 2010)
Log Message:
-----------
Updated release doc.
Modified Paths:
--------------
trunk/src/site/xdoc/how-to-release.xml
Modified: trunk/src/site/xdoc/how-to-release.xml
===================================================================
--- trunk/src/site/xdoc/how-to-release.xml 2010-10-18 16:01:49 UTC (rev 860)
+++ trunk/src/site/xdoc/how-to-release.xml 2010-10-18 16:02:25 UTC (rev 861)
@@ -36,7 +36,7 @@
<li>Ensure you repository is up to date by running: <tt>svn update</tt></li>
<li>Edit <tt>src/changes/changes.xml</tt> to set release date instead of "unknow"</li>
<li>Update readme.txt (at least update the version number)</li>
- <li>Update JWebUnit latest version in src/site/xdoc/index.xml</li>
+ <li>Update JWebUnit latest version in src/site/xdoc/index.xml, src/site/xdoc/installation.xml, jwebunit-htmlunit-plugin/src/site/xdoc/index.xml, jwebunit-selenium-plugin/src/site/xdoc/index.xml</li>
<li>Commit the changes</li>
</ul>
</p>
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <he...@us...> - 2010-10-18 16:01:58
|
Revision: 860
http://jwebunit.svn.sourceforge.net/jwebunit/?rev=860&view=rev
Author: henryju
Date: 2010-10-18 16:01:49 +0000 (Mon, 18 Oct 2010)
Log Message:
-----------
JUnit 4 migration part 2: migrated WebTestCaseGenerator to JUnit 4 (and updated tests and documentation accordingly).
Modified Paths:
--------------
trunk/jwebunit-commons-tests/pom.xml
trunk/jwebunit-commons-tests/src/main/java/net/sourceforge/jwebunit/tests/ButtonAssertionsTest.java
trunk/jwebunit-commons-tests/src/main/java/net/sourceforge/jwebunit/tests/CharsetTest.java
trunk/jwebunit-commons-tests/src/main/java/net/sourceforge/jwebunit/tests/CustomTesterTest.java
trunk/jwebunit-commons-tests/src/main/java/net/sourceforge/jwebunit/tests/ExpectedTableAssertionsHtmlTest.java
trunk/jwebunit-commons-tests/src/main/java/net/sourceforge/jwebunit/tests/ExpectedTableAssertionsXHtmlTest.java
trunk/jwebunit-commons-tests/src/main/java/net/sourceforge/jwebunit/tests/FormAssertionsTest.java
trunk/jwebunit-commons-tests/src/main/java/net/sourceforge/jwebunit/tests/FormAssertionsWithLabelTest.java
trunk/jwebunit-commons-tests/src/main/java/net/sourceforge/jwebunit/tests/FormSubmissionTest.java
trunk/jwebunit-commons-tests/src/main/java/net/sourceforge/jwebunit/tests/FramesAndWindowsTest.java
trunk/jwebunit-commons-tests/src/main/java/net/sourceforge/jwebunit/tests/HelloWorldTest.java
trunk/jwebunit-commons-tests/src/main/java/net/sourceforge/jwebunit/tests/HtmlParsingTest.java
trunk/jwebunit-commons-tests/src/main/java/net/sourceforge/jwebunit/tests/IElementTest.java
trunk/jwebunit-commons-tests/src/main/java/net/sourceforge/jwebunit/tests/ImageTest.java
trunk/jwebunit-commons-tests/src/main/java/net/sourceforge/jwebunit/tests/JUnitPerfTest.java
trunk/jwebunit-commons-tests/src/main/java/net/sourceforge/jwebunit/tests/JWebUnitAPITestCase.java
trunk/jwebunit-commons-tests/src/main/java/net/sourceforge/jwebunit/tests/JavaScriptEventsTest.java
trunk/jwebunit-commons-tests/src/main/java/net/sourceforge/jwebunit/tests/JavaScriptTest.java
trunk/jwebunit-commons-tests/src/main/java/net/sourceforge/jwebunit/tests/NavigationTest.java
trunk/jwebunit-commons-tests/src/main/java/net/sourceforge/jwebunit/tests/NonHtmlContentTest.java
trunk/jwebunit-commons-tests/src/main/java/net/sourceforge/jwebunit/tests/RedirectionTest.java
trunk/jwebunit-commons-tests/src/main/java/net/sourceforge/jwebunit/tests/ResourceBundleAssertionsTest.java
trunk/jwebunit-commons-tests/src/main/java/net/sourceforge/jwebunit/tests/ResponseServletTest.java
trunk/jwebunit-commons-tests/src/main/java/net/sourceforge/jwebunit/tests/SelectOptionsTest.java
trunk/jwebunit-commons-tests/src/main/java/net/sourceforge/jwebunit/tests/TableAssertionsTest.java
trunk/jwebunit-commons-tests/src/main/java/net/sourceforge/jwebunit/tests/TestContextTest.java
trunk/jwebunit-commons-tests/src/main/java/net/sourceforge/jwebunit/tests/WebAssertionsTest.java
trunk/jwebunit-commons-tests/src/main/java/net/sourceforge/jwebunit/tests/WebCookieTest.java
trunk/jwebunit-commons-tests/src/main/java/net/sourceforge/jwebunit/tests/XPathTest.java
trunk/jwebunit-commons-tests/src/main/java/net/sourceforge/jwebunit/tests/util/JettySetup.java
trunk/jwebunit-commons-tests/src/main/java/net/sourceforge/jwebunit/tests/util/reflect/MethodInvoker.java
trunk/jwebunit-commons-tests/src/test/java/net/sourceforge/jwebunit/tests/util/reflect/MethodInvokerTest.java
trunk/jwebunit-htmlunit-plugin/src/test/java/net/sourceforge/jwebunit/htmlunit/JWebUnitTest.java
trunk/jwebunit-htmlunit-plugin/src/test/java/net/sourceforge/jwebunit/htmlunit/RefreshHandlerTest.java
trunk/jwebunit-selenium-plugin/src/test/java/net/sourceforge/jwebunit/selenium/JWebUnitTest.java
trunk/jwebunit-webtestcase-generator/src/main/javacc/Java1.5.jj
trunk/pom.xml
trunk/src/site/xdoc/migration.xml
Added Paths:
-----------
trunk/jwebunit-commons-tests/src/main/java/net/sourceforge/jwebunit/tests/util/Concurrent.java
trunk/jwebunit-commons-tests/src/main/java/net/sourceforge/jwebunit/tests/util/ConcurrentRule.java
trunk/jwebunit-commons-tests/src/main/java/net/sourceforge/jwebunit/tests/util/reflect/StaticMethodInvoker.java
Modified: trunk/jwebunit-commons-tests/pom.xml
===================================================================
--- trunk/jwebunit-commons-tests/pom.xml 2010-10-18 09:48:01 UTC (rev 859)
+++ trunk/jwebunit-commons-tests/pom.xml 2010-10-18 16:01:49 UTC (rev 860)
@@ -15,10 +15,6 @@
<artifactId>junit</artifactId>
</dependency>
<dependency>
- <groupId>junitperf</groupId>
- <artifactId>junitperf</artifactId>
- </dependency>
- <dependency>
<groupId>org.mortbay.jetty</groupId>
<artifactId>jetty</artifactId>
</dependency>
Modified: trunk/jwebunit-commons-tests/src/main/java/net/sourceforge/jwebunit/tests/ButtonAssertionsTest.java
===================================================================
--- trunk/jwebunit-commons-tests/src/main/java/net/sourceforge/jwebunit/tests/ButtonAssertionsTest.java 2010-10-18 09:48:01 UTC (rev 859)
+++ trunk/jwebunit-commons-tests/src/main/java/net/sourceforge/jwebunit/tests/ButtonAssertionsTest.java 2010-10-18 16:01:49 UTC (rev 860)
@@ -19,6 +19,10 @@
package net.sourceforge.jwebunit.tests;
+import static net.sourceforge.jwebunit.junit.JWebUnit.*;
+
+import org.junit.Test;
+
public class ButtonAssertionsTest extends JWebUnitAPITestCase {
public void setUp() throws Exception {
@@ -26,6 +30,7 @@
setBaseUrl(HOST_PATH + "/ButtonAssertionsTest");
}
+ @Test
public void testAssertButtonwithOneFormfound() {
beginAt("/pageWithOneForm.html");
assertButtonPresent("button1");
@@ -40,6 +45,7 @@
assertButtonPresentWithText("Input button");
}
+ @Test
public void testAssertButtonwithTowFormsfound() {
beginAt("/pageWithTwoForms.html");
assertButtonPresent("button1");
@@ -58,6 +64,7 @@
assertButtonPresent("buttonOutside");
}
+ @Test
public void testAssertButtonWithText() {
beginAt("/pageWithTwoForms.html");
assertButtonPresentWithText("Testbutton");
Modified: trunk/jwebunit-commons-tests/src/main/java/net/sourceforge/jwebunit/tests/CharsetTest.java
===================================================================
--- trunk/jwebunit-commons-tests/src/main/java/net/sourceforge/jwebunit/tests/CharsetTest.java 2010-10-18 09:48:01 UTC (rev 859)
+++ trunk/jwebunit-commons-tests/src/main/java/net/sourceforge/jwebunit/tests/CharsetTest.java 2010-10-18 16:01:49 UTC (rev 860)
@@ -19,42 +19,39 @@
package net.sourceforge.jwebunit.tests;
-import junit.framework.Test;
-import junit.framework.TestSuite;
-import net.sourceforge.jwebunit.tests.util.JettySetup;
+import static net.sourceforge.jwebunit.junit.JWebUnit.*;
+import org.junit.Test;
+
/**
* Make sure JWebUnit handles character conversions properly.
*
* @author <a href="mailto:je...@sw...">Jesse Wilson</a>
*/
public class CharsetTest extends JWebUnitAPITestCase {
- public CharsetTest(String name) {
- super(name);
- }
- public static Test suite() {
- return new JettySetup(new TestSuite(CharsetTest.class));
- }
-
public void setUp() throws Exception {
super.setUp();
setBaseUrl(HOST_PATH + "/CharsetTest");
beginAt("/charset.html_utf-8");
}
+ @Test
public void testEuro() {
assertTextFieldEquals("eur", "\u20AC");
}
+ @Test
public void testDollar() {
assertTextFieldEquals("usd", "$");
}
+ @Test
public void testYen() {
assertTextFieldEquals("yen", "\u00A5");
}
+ @Test
public void testPound() {
assertTextFieldEquals("gbp", "\u00A3");
}
Modified: trunk/jwebunit-commons-tests/src/main/java/net/sourceforge/jwebunit/tests/CustomTesterTest.java
===================================================================
--- trunk/jwebunit-commons-tests/src/main/java/net/sourceforge/jwebunit/tests/CustomTesterTest.java 2010-10-18 09:48:01 UTC (rev 859)
+++ trunk/jwebunit-commons-tests/src/main/java/net/sourceforge/jwebunit/tests/CustomTesterTest.java 2010-10-18 16:01:49 UTC (rev 860)
@@ -20,11 +20,16 @@
package net.sourceforge.jwebunit.tests;
+import static net.sourceforge.jwebunit.junit.JWebUnit.assertTitleEquals;
+import static net.sourceforge.jwebunit.junit.JWebUnit.beginAt;
+import static net.sourceforge.jwebunit.junit.JWebUnit.getTestContext;
+import static net.sourceforge.jwebunit.junit.JWebUnit.setCustomTester;
import net.sourceforge.jwebunit.junit.WebTester;
-import net.sourceforge.jwebunit.tests.util.JettySetup;
-import junit.framework.Test;
-import junit.framework.TestSuite;
+import org.junit.After;
+import org.junit.Test;
+
+
/**
* Test the new constructor methods for custom web testers
*
@@ -53,22 +58,20 @@
}
- public CustomTesterTest() {
- super("CustomTesterTest", new MyWebTester());
- }
-
- public static Test suite() {
- Test suite = new TestSuite(CustomTesterTest.class);
- return new JettySetup(suite);
- }
-
public void setUp() throws Exception {
+ setCustomTester(new MyWebTester());
super.setUp();
getTestContext().setBaseUrl(HOST_PATH + "/CustomTesterTest");
}
+ @Test
public void testCustomTester() throws Throwable {
beginAt("/test.html");
assertTitleEquals("test"); // this will normally fail for a non-custom class
}
+
+ @After
+ public void cleanup() {
+ setCustomTester(null);
+ }
}
Modified: trunk/jwebunit-commons-tests/src/main/java/net/sourceforge/jwebunit/tests/ExpectedTableAssertionsHtmlTest.java
===================================================================
--- trunk/jwebunit-commons-tests/src/main/java/net/sourceforge/jwebunit/tests/ExpectedTableAssertionsHtmlTest.java 2010-10-18 09:48:01 UTC (rev 859)
+++ trunk/jwebunit-commons-tests/src/main/java/net/sourceforge/jwebunit/tests/ExpectedTableAssertionsHtmlTest.java 2010-10-18 16:01:49 UTC (rev 860)
@@ -19,28 +19,26 @@
package net.sourceforge.jwebunit.tests;
-import junit.framework.Test;
-import junit.framework.TestSuite;
+import static net.sourceforge.jwebunit.junit.JWebUnit.beginAt;
+import static net.sourceforge.jwebunit.junit.JWebUnit.setBaseUrl;
+
+import org.junit.Test;
+
import net.sourceforge.jwebunit.html.Cell;
import net.sourceforge.jwebunit.html.Table;
-import net.sourceforge.jwebunit.tests.util.JettySetup;
/**
* Test table equals assertions using expected tables.
*/
public class ExpectedTableAssertionsHtmlTest extends JWebUnitAPITestCase {
- public static Test suite() {
- return new JettySetup(new TestSuite(
- ExpectedTableAssertionsHtmlTest.class));
- }
-
public void setUp() throws Exception {
super.setUp();
setBaseUrl(HOST_PATH + "/ExpectedTableAssertionsTest");
beginAt("/TableAssertionsTestPageHtml.html");
}
+ @Test
public void testAssertTableEquals() throws Throwable {
Cell[][] cells = new Cell[4][];
cells[0] = new Cell[3];
@@ -64,6 +62,7 @@
assertPass("assertTableEquals", new Object[] { "myTable", table });
}
+ @Test
public void testAssertTableEqualsMissingRows() throws Throwable {
Cell[][] cells = new Cell[3][];
cells[0] = new Cell[3];
Modified: trunk/jwebunit-commons-tests/src/main/java/net/sourceforge/jwebunit/tests/ExpectedTableAssertionsXHtmlTest.java
===================================================================
--- trunk/jwebunit-commons-tests/src/main/java/net/sourceforge/jwebunit/tests/ExpectedTableAssertionsXHtmlTest.java 2010-10-18 09:48:01 UTC (rev 859)
+++ trunk/jwebunit-commons-tests/src/main/java/net/sourceforge/jwebunit/tests/ExpectedTableAssertionsXHtmlTest.java 2010-10-18 16:01:49 UTC (rev 860)
@@ -20,27 +20,25 @@
package net.sourceforge.jwebunit.tests;
-import junit.framework.Test;
-import junit.framework.TestSuite;
+import org.junit.Test;
+
import net.sourceforge.jwebunit.html.Cell;
import net.sourceforge.jwebunit.html.Table;
-import net.sourceforge.jwebunit.tests.util.JettySetup;
+import static net.sourceforge.jwebunit.junit.JWebUnit.*;
+
/**
* Test table equals assertions using expected tables.
*/
public class ExpectedTableAssertionsXHtmlTest extends JWebUnitAPITestCase {
- public static Test suite() {
- return new JettySetup(new TestSuite(ExpectedTableAssertionsXHtmlTest.class));
- }
-
public void setUp() throws Exception {
super.setUp();
setBaseUrl(HOST_PATH + "/ExpectedTableAssertionsTest");
beginAt("/TableAssertionsTestPageXHtml.html");
}
+ @Test
public void testAssertTableEquals() throws Throwable {
Cell[][] cells = new Cell[4][];
cells[0] = new Cell[3];
@@ -64,6 +62,7 @@
assertPass("assertTableEquals", new Object[]{"myTable", table});
}
+ @Test
public void testAssertTableEqualsMissingRows() throws Throwable {
Cell[][] cells = new Cell[3][];
cells[0] = new Cell[3];
Modified: trunk/jwebunit-commons-tests/src/main/java/net/sourceforge/jwebunit/tests/FormAssertionsTest.java
===================================================================
--- trunk/jwebunit-commons-tests/src/main/java/net/sourceforge/jwebunit/tests/FormAssertionsTest.java 2010-10-18 09:48:01 UTC (rev 859)
+++ trunk/jwebunit-commons-tests/src/main/java/net/sourceforge/jwebunit/tests/FormAssertionsTest.java 2010-10-18 16:01:49 UTC (rev 860)
@@ -19,23 +19,21 @@
package net.sourceforge.jwebunit.tests;
+import org.junit.Test;
+
import net.sourceforge.jwebunit.api.IElement;
-import net.sourceforge.jwebunit.tests.util.JettySetup;
-import junit.framework.Test;
-import junit.framework.TestSuite;
+import static net.sourceforge.jwebunit.junit.JWebUnit.*;
+import static org.junit.Assert.*;
+
public class FormAssertionsTest extends JWebUnitAPITestCase {
- public static Test suite() {
- Test suite = new TestSuite(FormAssertionsTest.class);
- return new JettySetup(suite);
- }
-
public void setUp() throws Exception {
super.setUp();
setBaseUrl(HOST_PATH + "/FormAssertionsTest");
}
+ @Test
public void testAssertButtonWithTextPresent() {
beginAt("/assertButtonWithText.html");
assertButtonPresentWithText("foo");
@@ -43,6 +41,7 @@
assertButtonNotPresentWithText("foobar");
}
+ @Test
public void testAssertFormParameterPresent() throws Throwable {
beginAt("/testPage.html");
assertPassFail("assertFormElementPresent", "testInputElement", "noSuchElement");
@@ -51,11 +50,13 @@
assertPass("assertFormElementPresent", "text");
}
+ @Test
public void testAssertFormParameterNotPresent() throws Throwable {
beginAt("/testPage.html");
assertPassFail("assertFormElementNotPresent", "noSuchElement", "testInputElement");
}
+ @Test
public void testAssertFormPresent() throws Throwable {
beginAt("/testPage.html");
assertPass("assertFormPresent", NOARGS);
@@ -64,6 +65,7 @@
assertPass("assertFormNotPresent", NOARGS);
}
+ @Test
public void testAssertFormPresentByName() throws Throwable {
beginAt("/testPage.html");
assertPass("assertFormPresent", new String[]{"form2"});
@@ -71,6 +73,7 @@
assertPass("assertFormNotPresent", new String[]{"noform"});
}
+ @Test
public void testAssertFormElementEquals() throws Throwable {
beginAt("/testPage.html");
assertPassFail("assertTextFieldEquals", new Object[]{"testInputElement", "testValue"}, new Object[]{"testInputElement", "noSuchValue"});
@@ -88,12 +91,14 @@
assertPassFail("assertTextFieldEquals", new Object[]{"passwordelement", "password"}, new Object[]{"passwordelement", "noSuchValue"});
}
+ @Test
public void testCheckboxSelected() throws Throwable {
beginAt("/testPage.html");
assertPassFail("assertCheckboxSelected", "checkboxselected", "checkboxnotselected");
assertFail("assertCheckboxSelected", "nosuchbox");
}
+ @Test
public void testCheckboxSelectedByName() throws Throwable {
beginAt("/testPage.html");
assertPassFail("assertCheckboxSelected", new Object[]{"checkboxnotselected", "actuallyselected"},
@@ -101,12 +106,14 @@
assertFail("assertCheckboxSelected", new Object[]{"checkboxselected", "nosuchvalue"});
}
+ @Test
public void testCheckboxNotSelected() throws Throwable {
beginAt("/testPage.html");
assertPassFail("assertCheckboxNotSelected", "checkboxnotselected", "checkboxselected");
assertFail("assertCheckboxNotSelected", "nosuchbox");
}
+ @Test
public void testCheckboxNotSelectedByName() throws Throwable {
beginAt("/testPage.html");
assertPassFail("assertCheckboxNotSelected", new Object[]{"checkboxselected", "actuallynotselected"},
@@ -114,16 +121,19 @@
assertFail("assertCheckboxNotSelected", new Object[]{"checkboxnotselected", "nosuchvalue"});
}
+ @Test
public void testAssertSubmitButtonPresent() throws Throwable {
beginAt("/testPage.html");
assertPassFail("assertSubmitButtonPresent", "submitButton", "noSuchButton");
}
+ @Test
public void testAssertSubmitButtonNotPresent() throws Throwable {
beginAt("/testPage.html");
assertPassFail("assertSubmitButtonNotPresent", "noSuchButton", "submitButton");
}
+ @Test
public void testAssertSubmitButtonValue() throws Throwable {
beginAt("/testPage.html");
assertPassFail("assertSubmitButtonPresent",
@@ -131,16 +141,19 @@
new Object[]{"submitButton", "noSuchLabel"});
}
+ @Test
public void testAssertResetButtonPresent() throws Throwable {
beginAt("/testPage.html");
assertPassFail("assertResetButtonPresent", "resetButton", "noSuchButton");
}
+ @Test
public void testAssertResetButtonNotPresent() throws Throwable {
beginAt("/testPage.html");
assertPassFail("assertResetButtonNotPresent", "noSuchButton", "resetButton");
}
+ @Test
public void testAssertRadioOptionPresent() throws Throwable {
beginAt("/testPage.html");
assertPassFail("assertRadioOptionPresent",
@@ -148,6 +161,7 @@
new String[]{"cool", "fish"});
}
+ @Test
public void testAssertRadioOptionNotPresent() throws Throwable {
beginAt("/testPage.html");
assertPassFail("assertRadioOptionNotPresent",
@@ -155,6 +169,7 @@
new String[]{"cool", "cat"});
}
+ @Test
public void testAssertRadioOptionSelected() throws Throwable {
beginAt("/testPage.html");
assertPassFail("assertRadioOptionSelected",
@@ -162,11 +177,13 @@
new String[]{"cool", "cat"});
}
+ @Test
public void testAssertRadioOptionNotSelected() throws Throwable {
beginAt("/testPage.html");
assertPassFail("assertRadioOptionNotSelected", new String[]{"cool", "cat"}, new String[]{"cool", "dog"});
}
+ @Test
public void testAssertSelectOptionPresent() throws Throwable {
beginAt("/testPage.html");
assertPassFail("assertSelectOptionPresent",
@@ -174,6 +191,7 @@
new String[]{"selectOption", "NoSuchOption"});
}
+ @Test
public void testAssertSelectOptionNotPresent() throws Throwable {
beginAt("/testPage.html");
assertPassFail("assertSelectOptionNotPresent",
@@ -181,6 +199,7 @@
new String[]{"selectOption", "One"});
}
+ @Test
public void testAssertSelectOptionValuePresent() throws Throwable {
beginAt("/testPage.html");
assertPassFail("assertSelectOptionValuePresent",
@@ -188,6 +207,7 @@
new String[]{"selectOption", "NoSuchOption"});
}
+ @Test
public void testAssertSelectOptionValueNotPresent() throws Throwable {
beginAt("/testPage.html");
assertPassFail("assertSelectOptionValueNotPresent",
@@ -195,6 +215,7 @@
new String[]{"selectOption", "1"});
}
+ @Test
public void testAssertSelectOptionsEqual() throws Throwable {
beginAt("/testPage.html");
assertPass("assertSelectOptionsEqual", new Object[]{"select1", new String[]{"one", "two", "three", "four"}});
@@ -202,6 +223,7 @@
assertFail("assertSelectOptionsEqual", new Object[]{"select1", new String[]{"one", "two", "three", "four", "five"}});
}
+ @Test
public void testAssertSelectOptionsNotEqual() throws Throwable {
beginAt("/testPage.html");
assertFail("assertSelectOptionsNotEqual", new Object[]{"select1", new String[]{"one", "two", "three", "four"}});
@@ -209,6 +231,7 @@
assertPass("assertSelectOptionsNotEqual", new Object[]{"select1", new String[]{"one", "two", "three", "four", "five"}});
}
+ @Test
public void testAssertSelectOptionValuesEqual() throws Throwable {
beginAt("/testPage.html");
assertPass("assertSelectOptionValuesEqual", new Object[]{"select1", new String[]{"1", "2", "3", "4"}});
@@ -216,6 +239,7 @@
assertFail("assertSelectOptionValuesEqual", new Object[]{"select1", new String[]{"1", "2", "3", "4", "5"}});
}
+ @Test
public void testAssertSelectOptionValuesNotEqual() throws Throwable {
beginAt("/testPage.html");
assertFail("assertSelectOptionValuesNotEqual", new Object[]{"select1", new String[]{"1", "2", "3", "4"}});
@@ -223,21 +247,25 @@
assertPass("assertSelectOptionValuesNotEqual", new Object[]{"select1", new String[]{"1", "2", "3", "4", "5"}});
}
+ @Test
public void testAssertSelectedOptionEquals() throws Throwable {
beginAt("/testPage.html");
assertPassFail("assertSelectedOptionEquals", new String[]{"select1", "one"}, new String[]{"select1", "two"});
}
+ @Test
public void testAssertSelectedOptionValueEquals() throws Throwable {
beginAt("/testPage.html");
assertPassFail("assertSelectedOptionValueEquals", new String[]{"select1", "1"}, new String[]{"select1", "2"});
}
+ @Test
public void testAssertButtonPresent() throws Throwable {
beginAt("/testPage.html");
assertPassFail("assertButtonPresent", "b1", "nobutton");
}
+ @Test
public void testAssertButtonNotPresent() throws Throwable {
beginAt("/testPage.html");
assertPassFail("assertButtonNotPresent", "nobutton", "b1");
@@ -246,6 +274,7 @@
/**
* Test elements with complicated names.
*/
+ @Test
public void testComplicatedElementNames() {
beginAt("/testPage.html");
@@ -264,6 +293,7 @@
/**
* Testing for issue 1996193: clickRadioOption does not work as expected
*/
+ @Test
public void testIssue1996193() {
beginAt("/testPage.html");
@@ -277,6 +307,7 @@
/**
* tests for label elements
*/
+ @Test
public void testLabels() {
beginAt("/testPage.html");
@@ -308,6 +339,7 @@
/**
* Test setting elements retrieved through labels
*/
+ @Test
public void testSetLabels() {
beginAt("/testPage.html");
@@ -345,6 +377,7 @@
* Even though the element has no value set (i.e. getAttribute("value") == null),
* it should still qualify as equal to an empty string.
*/
+ @Test
public void testLabeledEmptyElement() {
beginAt("/testPage.html");
assertLabeledFieldEquals("label9", "");
Modified: trunk/jwebunit-commons-tests/src/main/java/net/sourceforge/jwebunit/tests/FormAssertionsWithLabelTest.java
===================================================================
--- trunk/jwebunit-commons-tests/src/main/java/net/sourceforge/jwebunit/tests/FormAssertionsWithLabelTest.java 2010-10-18 09:48:01 UTC (rev 859)
+++ trunk/jwebunit-commons-tests/src/main/java/net/sourceforge/jwebunit/tests/FormAssertionsWithLabelTest.java 2010-10-18 16:01:49 UTC (rev 860)
@@ -19,28 +19,25 @@
package net.sourceforge.jwebunit.tests;
-import net.sourceforge.jwebunit.tests.util.JettySetup;
-import junit.framework.Test;
-import junit.framework.TestSuite;
+import static net.sourceforge.jwebunit.junit.JWebUnit.*;
+import org.junit.Test;
+
public class FormAssertionsWithLabelTest extends JWebUnitAPITestCase {
- public static Test suite() {
- Test suite = new TestSuite(FormAssertionsWithLabelTest.class);
- return new JettySetup(suite);
- }
-
public void setUp() throws Exception {
super.setUp();
setBaseUrl(HOST_PATH + "/FormAssertionsTest");
}
+ @Test
public void testAssertFormParameterPresentWithLabel() throws Throwable {
beginAt("/testPage.html");
assertPassFail("assertFormElementPresentWithLabel", "Test Input", "No Such Label");
assertFail("assertFormElementPresentWithLabel", "This is a test page");
}
+ @Test
public void testAssertFormParameterNotPresentWithLabel() throws Throwable {
beginAt("/testPage.html");
assertPassFail("assertFormElementNotPresentWithLabel", "No Such Label", "Test Input");
Modified: trunk/jwebunit-commons-tests/src/main/java/net/sourceforge/jwebunit/tests/FormSubmissionTest.java
===================================================================
--- trunk/jwebunit-commons-tests/src/main/java/net/sourceforge/jwebunit/tests/FormSubmissionTest.java 2010-10-18 09:48:01 UTC (rev 859)
+++ trunk/jwebunit-commons-tests/src/main/java/net/sourceforge/jwebunit/tests/FormSubmissionTest.java 2010-10-18 16:01:49 UTC (rev 860)
@@ -25,10 +25,11 @@
import java.io.FileWriter;
import java.io.IOException;
-import net.sourceforge.jwebunit.tests.util.JettySetup;
-import junit.framework.Test;
-import junit.framework.TestSuite;
+import org.junit.Test;
+import static net.sourceforge.jwebunit.junit.JWebUnit.*;
+import static org.junit.Assert.*;
+
/**
* Test form submission related methods of WebTestCase.
*
@@ -39,16 +40,12 @@
*/
public class FormSubmissionTest extends JWebUnitAPITestCase {
- public static Test suite() {
- Test suite = new TestSuite(FormSubmissionTest.class);
- return new JettySetup(suite);
- }
-
public void setUp() throws Exception {
super.setUp();
setBaseUrl(HOST_PATH + "/FormSubmissionTest");
}
+ @Test
public void testSetTextField() {
beginAt("/SingleNamedButtonForm.html");
setTextField("color", "blue");
@@ -61,6 +58,7 @@
assertTextPresent("color=red");
}
+ @Test
public void testSetTextArea() {
beginAt("/TextAreaForm.html");
setTextField("text", "sometext");
@@ -73,6 +71,7 @@
assertTextPresent("text=anothertext");
}
+ @Test
public void testSetFileField() {
beginAt("/InputFileForm.html");
File temp = null;
@@ -96,6 +95,7 @@
assertTextPresent("file=" + temp.getName() + "{abcdefgh}");
}
+ @Test
public void testSubmitImageInput() {
beginAt("/InputImageForm.html");
setTextField("color", "toto");
@@ -105,6 +105,7 @@
assertTextPresent("color=toto");
}
+ @Test
public void testSubmitImageInputByName() {
beginAt("/InputImageForm.html");
setTextField("color", "toto");
@@ -114,6 +115,7 @@
assertTextPresent("color=toto");
}
+ @Test
public void testCheckBoxSelection() {
beginAt("/SingleNamedButtonForm.html");
checkCheckbox("checkBox");
@@ -125,6 +127,7 @@
assertTextPresent("checkBox=,on");
}
+ @Test
public void testCheckBoxSelectionWithSameFieldName() {
beginAt("/CheckboxForm.html");
checkCheckbox("checkBox", "1");
@@ -134,6 +137,7 @@
assertTextPresent("checkBox=1,3" + System.getProperty("line.separator"));
}
+ @Test
public void testCheckBoxDeSelectionWithSameFieldName() {
beginAt("/CheckboxForm.html");
checkCheckbox("checkBox", "1");
@@ -143,6 +147,7 @@
assertTextPresent("checkBox=1");
}
+ @Test
public void testCheckBoxDeselection() {
beginAt("/SingleNamedButtonForm.html");
checkCheckbox("checkBox"); // Fail with httpunit because of hidden
@@ -154,6 +159,7 @@
assertTextPresent("color=blue" + System.getProperty("line.separator"));
}
+ @Test
public void testRadioSelection() {
beginAt("/RadioForm.html");
clickRadioOption("radio", "1");
@@ -170,6 +176,7 @@
assertTextPresent("radio=3" + System.getProperty("line.separator"));
}
+ @Test
public void testSingleFormSingleUnnamedButtonSubmission() {
beginAt("/SingleUnnamedButtonForm.html");
setTextField("color", "blue");
@@ -177,6 +184,7 @@
assertTextPresent("color=blue" + System.getProperty("line.separator"));
}
+ @Test
public void testSingleNamedButtonSubmission() {
beginAt("/SingleNamedButtonForm.html");
setTextField("color", "red");
@@ -184,6 +192,7 @@
assertTextPresent("color=red");
}
+ @Test
public void testSingleFormMultipleButtonSubmission() {
gotoMultiButtonPage();
submit("color");
@@ -193,6 +202,7 @@
assertTextPresent("color=blue");
}
+ @Test
public void testBogusParameter() {
gotoMultiButtonPage();
try {
@@ -203,6 +213,7 @@
}
}
+ @Test
public void testParamSetOnMultiForm() {
beginAt("/MultiFormPage.html");
setTextField("param1", "anyvalue");
@@ -212,6 +223,7 @@
assertTextPresent("param2=anyvalue");
}
+ @Test
public void testTextFieldSetOnMultiFormWithSameName() {
beginAt("/MultiFormPage.html");
setWorkingForm("form2");
@@ -230,11 +242,13 @@
assertTextPresent("email=anyvalue");
}
+ @Test
public void testSetWorkingFormById() {
beginAt("/MultiFormPage.html");
setWorkingForm("form5");
}
+ @Test
public void testSetWorkingFormWithSameName() {
beginAt("/MultiFormPage.html");
setWorkingForm("myForm", 0);
@@ -245,6 +259,7 @@
assertSubmitButtonPresent("myInput2");
}
+ @Test
public void testInvalidButton() {
beginAt("/InvalidActionForm.html");
try {
@@ -256,6 +271,7 @@
}
}
+ @Test
public void testUnnamedSubmitOnSpecificForm() {
beginAt("/MultiFormPage.html");
setTextField("param4", "anyvalue");
@@ -263,6 +279,7 @@
assertTextPresent("param4=anyvalue");
}
+ @Test
public void testNamedSubmitOnSpecificForm() {
beginAt("/MultiFormPage.html");
setTextField("param2", "anyvalue");
@@ -271,6 +288,7 @@
assertTextPresent("button2b=b2b");
}
+ @Test
public void testSubmissionReset() {
beginAt("/MultiFormPage.html");
setTextField("param2", "anyvalue");
@@ -280,6 +298,7 @@
assertTextPresent("button2b=b2b");
}
+ @Test
public void testSelectOption() {
beginAt("/MultiFormPage.html");
assertSelectedOptionEquals("select1", "one");
@@ -287,6 +306,7 @@
assertSelectedOptionEquals("select1", "two");
}
+ @Test
public void testSelectOptionInAnotherForm() {
beginAt("/MultiFormPage.html");
setWorkingForm("form6bis");
@@ -295,6 +315,7 @@
assertSelectedOptionEquals("select1", "five");
}
+ @Test
public void testSelectOptionByValue() {
beginAt("/MultiFormPage.html");
assertSelectedOptionValueEquals("select1", "1");
@@ -306,6 +327,7 @@
beginAt("/MultiNamedButtonForm.html");
}
+ @Test
public void testCachedForm() {
beginAt("/Submit1.html");
assertTextPresent("Page 1");
@@ -318,6 +340,7 @@
/**
* Submit input
*/
+ @Test
public void testClickButtonWithText1() {
beginAt("/SingleNamedButtonForm.html");
setTextField("color", "blue");
@@ -326,6 +349,7 @@
assertTextPresent("color=blue");
}
+ @Test
public void testSetHiddenField() {
beginAt("/SingleNamedButtonForm.html");
assertHiddenFieldPresent("hidden", "foo");
Modified: trunk/jwebunit-commons-tests/src/main/java/net/sourceforge/jwebunit/tests/FramesAndWindowsTest.java
===================================================================
--- trunk/jwebunit-commons-tests/src/main/java/net/sourceforge/jwebunit/tests/FramesAndWindowsTest.java 2010-10-18 09:48:01 UTC (rev 859)
+++ trunk/jwebunit-commons-tests/src/main/java/net/sourceforge/jwebunit/tests/FramesAndWindowsTest.java 2010-10-18 16:01:49 UTC (rev 860)
@@ -19,10 +19,11 @@
package net.sourceforge.jwebunit.tests;
-import junit.framework.Test;
-import junit.framework.TestSuite;
-import net.sourceforge.jwebunit.tests.util.JettySetup;
+import static net.sourceforge.jwebunit.junit.JWebUnit.*;
+import static org.junit.Assert.*;
+import org.junit.Test;
+
/**
* User: djoiner
* Date: Nov 21, 2002
@@ -30,11 +31,6 @@
*/
public class FramesAndWindowsTest extends JWebUnitAPITestCase {
- public static Test suite() {
- Test suite = new TestSuite(FramesAndWindowsTest.class);
- return new JettySetup(suite);
- }
-
public void setUp() throws Exception {
super.setUp();
setBaseUrl(HOST_PATH + "/FramesAndWindowsTest");
@@ -51,42 +47,42 @@
// ------------ windows test ------------
- public void testOpenWindow() throws Throwable {
+ @Test public void testOpenWindow() throws Throwable {
gotoRootAndOpenChild("ChildPage1");
assertPassFail("assertWindowPresent", new Object[]{"ChildPage1"}, new Object[]{"NoSuchChild"});
}
- public void testGotoWindow() {
+ @Test public void testGotoWindow() {
gotoRootAndOpenChild("ChildPage1");
gotoWindow("ChildPage1");
assertTextPresent("child 1");
}
- public void testGotoWindowByID() {
+ @Test public void testGotoWindowByID() {
gotoRootAndOpenChild("ChildPage3");
gotoWindow(1);
assertTextPresent("child 3");
}
- public void testGotoWindowByTitle() {
+ @Test public void testGotoWindowByTitle() {
gotoRootAndOpenChild("ChildPage2");
gotoWindowByTitle("Child Page 2");
assertTextPresent("child 2");
}
- public void testAssertWindowWithTitle() throws Throwable {
+ @Test public void testAssertWindowWithTitle() throws Throwable {
gotoRootAndOpenChild("ChildPage2");
assertPassFail("assertWindowPresentWithTitle", new Object[]{"Child Page 2"}, new Object[]{"NoSuchTitle"});
}
- public void testSwitchWindows() {
+ @Test public void testSwitchWindows() {
gotoRootAndOpenChild("ChildPage1");
gotoWindow("ChildPage1");
gotoRootWindow();
assertTextPresent("This is the Root");
}
- public void testCloseWindow() {
+ @Test public void testCloseWindow() {
beginAt("RootPage.html");
assertTitleEquals("This is the Root");
clickLink("ChildPage1");
@@ -97,7 +93,7 @@
assertTitleEquals("This is the Root");
}
- public void testAssertWindowCountEquals() {
+ @Test public void testAssertWindowCountEquals() {
beginAt("RootPage.html");
assertWindowCountEquals(1);
clickLink("ChildPage1");
@@ -109,7 +105,7 @@
// ----------- frames test --------------
- public void testGotoFrame() {
+ @Test public void testGotoFrame() {
beginAt("Frames.html");
assertFramePresent("TopFrame");
gotoFrame("TopFrame");
@@ -126,7 +122,7 @@
new Object[] { "BottomFrame" });
}
- public void testGetFrameSource() {
+ @Test public void testGetFrameSource() {
beginAt("Frames.html");
assertTrue(getPageSource().indexOf("<frameset rows=\"33%, 33%, 33%\">")>=0);
gotoFrame("TopFrame");
@@ -134,7 +130,7 @@
assertTextPresent("TopFrame");
}
- public void testGotoFrameById() {
+ @Test public void testGotoFrameById() {
beginAt("Frames.html");
assertFramePresent("frame1");
gotoFrame("frame1");
@@ -150,7 +146,7 @@
assertException(RuntimeException.class, "gotoFrame", new Object[] { "TopFrame" });
}
- public void testGotoInlineFrame() {
+ @Test public void testGotoInlineFrame() {
beginAt("InlineFrame.html");
assertTextPresent("TopFrame");
// Is this how it should work? see also the test below
@@ -159,7 +155,7 @@
assertTextPresent("ContentFrame"); // only 'ContentFrame' matches frameset tag too
}
- public void testFormInputInFrame() {
+ @Test public void testFormInputInFrame() {
beginAt("Frames.html");
gotoFrame("ContentFrame");
assertFormPresent();
@@ -168,7 +164,7 @@
assertTextPresent("color=red" + System.getProperty("line.separator"));
}
- public void testFormInputInInlineFrame() {
+ @Test public void testFormInputInInlineFrame() {
beginAt("InlineFrame.html");
gotoFrame("ContentFrame");
assertFormPresent();
@@ -178,7 +174,7 @@
}
//TODO this just posts to a new frameset inside the frame, is the test needed?
- public void testFormInputInFrameToFrame() {
+ @Test public void testFormInputInFrameToFrame() {
beginAt("Frames.html");
gotoFrame("ContentFrame");
setTextField("color", "green");
Modified: trunk/jwebunit-commons-tests/src/main/java/net/sourceforge/jwebunit/tests/HelloWorldTest.java
===================================================================
--- trunk/jwebunit-commons-tests/src/main/java/net/sourceforge/jwebunit/tests/HelloWorldTest.java 2010-10-18 09:48:01 UTC (rev 859)
+++ trunk/jwebunit-commons-tests/src/main/java/net/sourceforge/jwebunit/tests/HelloWorldTest.java 2010-10-18 16:01:49 UTC (rev 860)
@@ -19,31 +19,27 @@
package net.sourceforge.jwebunit.tests;
-import junit.framework.Test;
-import junit.framework.TestSuite;
-import net.sourceforge.jwebunit.tests.util.JettySetup;
+import static net.sourceforge.jwebunit.junit.JWebUnit.assertTitleEquals;
+import static net.sourceforge.jwebunit.junit.JWebUnit.assertTitleNotSame;
+import static net.sourceforge.jwebunit.junit.JWebUnit.beginAt;
+import static net.sourceforge.jwebunit.junit.JWebUnit.setBaseUrl;
+import org.junit.Test;
+
/**
* Sanity check for the Jetty setup.
*
* @author Martijn Dashorst
*/
public class HelloWorldTest extends JWebUnitAPITestCase {
- public HelloWorldTest(String name) {
- super(name);
- }
- public static Test suite() {
- return new JettySetup(new TestSuite(HelloWorldTest.class));
- }
-
public void setUp() throws Exception {
super.setUp();
setBaseUrl(HOST_PATH);
beginAt("/helloworld.html");
}
- public void testTitle() {
+ @Test public void testTitle() {
assertTitleEquals("Hello, World!");
assertTitleNotSame("Goodbye, World!");
}
Modified: trunk/jwebunit-commons-tests/src/main/java/net/sourceforge/jwebunit/tests/HtmlParsingTest.java
===================================================================
--- trunk/jwebunit-commons-tests/src/main/java/net/sourceforge/jwebunit/tests/HtmlParsingTest.java 2010-10-18 09:48:01 UTC (rev 859)
+++ trunk/jwebunit-commons-tests/src/main/java/net/sourceforge/jwebunit/tests/HtmlParsingTest.java 2010-10-18 16:01:49 UTC (rev 860)
@@ -20,56 +20,55 @@
package net.sourceforge.jwebunit.tests;
-import junit.framework.Test;
-import junit.framework.TestSuite;
-import net.sourceforge.jwebunit.tests.util.JettySetup;
+import static net.sourceforge.jwebunit.junit.JWebUnit.assertElementPresent;
+import static net.sourceforge.jwebunit.junit.JWebUnit.assertFormPresent;
+import static net.sourceforge.jwebunit.junit.JWebUnit.beginAt;
+import static net.sourceforge.jwebunit.junit.JWebUnit.setBaseUrl;
+import static net.sourceforge.jwebunit.junit.JWebUnit.submit;
+import org.junit.Test;
+
/**
* Tests the use of HttpUnit and the types of html documents accepted.
*/
public class HtmlParsingTest extends JWebUnitAPITestCase {
- public static Test suite() {
- Test suite = new TestSuite(HtmlParsingTest.class);
- return new JettySetup(suite);
- }
-
public void setUp() throws Exception {
super.setUp();
setBaseUrl(HOST_PATH + "/HtmlTest/");
}
- public void testSimpleForm() {
+ @Test public void testSimpleForm() {
beginAt("SimpleForm.html");
assertFormPresent();
submit();
}
- public void testInvalidForm() {
+ @Test public void testInvalidForm() {
beginAt("InvalidForm.html");
assertFormPresent();
submit();
}
- public void testInvalidFormNoDoctype() {
+ @Test public void testInvalidFormNoDoctype() {
beginAt("InvalidFormNoDoctype.html");
assertFormPresent();
submit();
}
- public void testValidComplexForm() {
+ @Test public void testValidComplexForm() {
beginAt("ValidComplexForm.html");
assertFormPresent();
submit();
}
- public void testValidFormNoDoctype() {
+ @Test public void testValidFormNoDoctype() {
beginAt("ValidFormNoDoctype.html");
assertFormPresent();
submit();
}
- public void testXhtmlStrict() {
+ @Test public void testXhtmlStrict() {
beginAt("XhtmlStrict.html");
// run a method that gets the DOM
assertElementPresent("div1");
Modified: trunk/jwebunit-commons-tests/src/main/java/net/sourceforge/jwebunit/tests/IElementTest.java
===================================================================
--- trunk/jwebunit-commons-tests/src/main/java/net/sourceforge/jwebunit/tests/IElementTest.java 2010-10-18 09:48:01 UTC (rev 859)
+++ trunk/jwebunit-commons-tests/src/main/java/net/sourceforge/jwebunit/tests/IElementTest.java 2010-10-18 16:01:49 UTC (rev 860)
@@ -19,14 +19,30 @@
package net.sourceforge.jwebunit.tests;
+import static net.sourceforge.jwebunit.junit.JWebUnit.assertCommentNotPresent;
+import static net.sourceforge.jwebunit.junit.JWebUnit.assertCommentPresent;
+import static net.sourceforge.jwebunit.junit.JWebUnit.assertElementPresent;
+import static net.sourceforge.jwebunit.junit.JWebUnit.assertFormElementPresent;
+import static net.sourceforge.jwebunit.junit.JWebUnit.assertMatch;
+import static net.sourceforge.jwebunit.junit.JWebUnit.assertNotMatch;
+import static net.sourceforge.jwebunit.junit.JWebUnit.assertTextFieldEquals;
+import static net.sourceforge.jwebunit.junit.JWebUnit.beginAt;
+import static net.sourceforge.jwebunit.junit.JWebUnit.getElementById;
+import static net.sourceforge.jwebunit.junit.JWebUnit.getElementByXPath;
+import static net.sourceforge.jwebunit.junit.JWebUnit.getElementsByXPath;
+import static net.sourceforge.jwebunit.junit.JWebUnit.setBaseUrl;
+import static net.sourceforge.jwebunit.junit.JWebUnit.setTextField;
+import static org.junit.Assert.assertEquals;
+import static org.junit.Assert.assertNotNull;
+import static org.junit.Assert.fail;
+
import java.util.Date;
import java.util.List;
-import junit.framework.Test;
-import junit.framework.TestSuite;
import net.sourceforge.jwebunit.api.IElement;
-import net.sourceforge.jwebunit.tests.util.JettySetup;
+import org.junit.Test;
+
/**
* Test the IElement interface
*
@@ -34,18 +50,13 @@
*/
public class IElementTest extends JWebUnitAPITestCase {
- public static Test suite() {
- Test suite = new TestSuite(IElementTest.class);
- return new JettySetup(suite);
- }
-
public void setUp() throws Exception {
super.setUp();
setBaseUrl(HOST_PATH + "/IElementTest");
beginAt("/template.html");
}
- public void testSimple() {
+ @Test public void testSimple() {
// test an element that exists
IElement element = getElementByXPath("//input[@id='test']");
assertNotNull(element);
@@ -55,7 +66,7 @@
assertEquals(element.getAttribute("value"), "test3");
}
- public void testMissing() {
+ @Test public void testMissing() {
// a missing element should throw an exception
try {
getElementByXPath("//input[@id='test2']");
@@ -68,7 +79,7 @@
/**
* Test parent, child methods
*/
- public void testChildren() {
+ @Test public void testChildren() {
assertElementPresent("first");
IElement element = getElementById("first");
assertEquals(element.getName(), "li");
@@ -95,7 +106,7 @@
/**
* Test getting the XPath for multiple possible results
*/
- public void testMultiple() {
+ @Test public void testMultiple() {
List<IElement> children = getElementsByXPath("//li");
assertEquals(children.size(), 4);
assertEquals(children.get(0).getTextContent(), "one");
@@ -108,7 +119,7 @@
/**
* change the element and make sure XPath has changed
*/
- public void testChanging() {
+ @Test public void testChanging() {
{
IElement element = getElementByXPath("//input[@id='test']");
assertNotNull(element);
@@ -137,7 +148,7 @@
}
- public void testWithXpath() {
+ @Test public void testWithXpath() {
IElement element = getElementByXPath("//body");
assertNotNull(element);
assertEquals("body", element.getName());
@@ -174,7 +185,7 @@
* Test that setting attributes manually (e.g setAttribute("value")
* properly calls any attached Javascript.
*/
- public void testAttributeJavascript() {
+ @Test public void testAttributeJavascript() {
String testingText = new Date().toString();
{
@@ -202,7 +213,7 @@
/**
* Tests searching for comments.
*/
- public void testComments() {
+ @Test public void testComments() {
// whitespace is ignored
assertCommentPresent("a comment");
assertCommentPresent("another comment");
@@ -218,7 +229,7 @@
* Test preceding element XPath.
* preceding: "Selects everything in the document that is before the start tag of the current node"
*/
- public void testPreceding() {
+ @Test public void testPreceding() {
IElement element = getElementById("first"); // li
// should get the first <input>, which is
// <input id="test" name="element_name" value="test3">
@@ -233,7 +244,7 @@
* correctly.
*
*/
- public void testIElementEquals() {
+ @Test public void testIElementEquals() {
// through getElementById
IElement container1 = getElementById("container");
Modified: trunk/jwebunit-commons-tests/src/main/java/net/sourceforge/jwebunit/tests/ImageTest.java
===================================================================
--- trunk/jwebunit-commons-tests/src/main/java/net/sourceforge/jwebunit/tests/ImageTest.java 2010-10-18 09:48:01 UTC (rev 859)
+++ trunk/jwebunit-commons-tests/src/main/java/net/sourceforge/jwebunit/tests/ImageTest.java 2010-10-18 16:01:49 UTC (rev 860)
@@ -19,33 +19,35 @@
package net.sourceforge.jwebunit.tests;
-import junit.framework.Test;
-import junit.framework.TestSuite;
-import net.sourceforge.jwebunit.tests.util.JettySetup;
+import static net.sourceforge.jwebunit.junit.JWebUnit.assertImagePresent;
+import static net.sourceforge.jwebunit.junit.JWebUnit.assertImageValid;
+import static net.sourceforge.jwebunit.junit.JWebUnit.assertImageValidAndStore;
+import static net.sourceforge.jwebunit.junit.JWebUnit.beginAt;
+import static net.sourceforge.jwebunit.junit.JWebUnit.getImage;
+import static net.sourceforge.jwebunit.junit.JWebUnit.setBaseUrl;
+import static org.junit.Assert.assertNotNull;
-import javax.imageio.ImageIO;
import java.awt.Image;
import java.awt.image.BufferedImage;
import java.io.File;
+import javax.imageio.ImageIO;
+
+import org.junit.Test;
+
/**
*
* @author gjoseph
*/
public class ImageTest extends JWebUnitAPITestCase {
- public static Test suite() {
- Test suite = new TestSuite(ImageTest.class);
- return new JettySetup(suite);
- }
-
public void setUp() throws Exception {
super.setUp();
setBaseUrl(HOST_PATH + "/ImageTest");
beginAt("/PageWithImages.html");
}
- public void testSimpleImagePresenceAssertion() throws Throwable {
+ @Test public void testSimpleImagePresenceAssertion() throws Throwable {
assertImagePresent("images/Image1.gif", "image 1");
assertImagePresent("images/Image2.png", "image 2");
assertImagePresent("images/photos/Image3.jpg", "image 3");
@@ -57,23 +59,23 @@
assertFail("assertImagePresent", new Object[]{"images/Image2.png", "wrong alt"});
}
- public void testGifCanBeLoaded() throws Throwable {
+ @Test public void testGifCanBeLoaded() throws Throwable {
assertPass("assertImageValid", new Object[]{"images/Image1.gif", "image 1"});
}
- public void testPngCanBeLoaded() throws Throwable {
+ @Test public void testPngCanBeLoaded() throws Throwable {
assertPass("assertImageValid", new Object[]{"images/Image2.png", "image 2"});
}
- public void testJpgCanBeLoaded() throws Throwable {
+ @Test public void testJpgCanBeLoaded() throws Throwable {
assertPass("assertImageValid", new Object[]{"images/photos/Image3.jpg", "image 3"});
}
- public void testFailsOnInvalidImages() throws Throwable {
+ @Test public void testFailsOnInvalidImages() throws Throwable {
assertFail("assertImageValid", new Object[]{"images/InvalidImage.gif", "invalid image"});
}
- public void testSavesImage() throws Throwable {
+ @Test public void testSavesImage() throws Throwable {
File testOut = File.createTempFile("jwebunit-test-", ".png");
testOut.deleteOnExit();
assertImageValidAndStore("images/Image2.png", "image 2", testOut);
@@ -82,13 +84,13 @@
assertNotNull(testImg);
}
- public void testImagesAreExposed() throws Throwable {
+ @Test public void testImagesAreExposed() throws Throwable {
Image image = getImage("images/Image1.gif", "image 1");
// let's just assume it's ok if the image is there
assertNotNull(image);
}
- public void testRelativePathsAreCorrectlyResolved() {
+ @Test public void testRelativePathsAreCorrectlyResolved() {
beginAt("/somedir/AnotherPageWithImages.html");
assertImageValid("Image4.gif", "image 4 - same dir");
assertImageValid("images/Image5.png", "image 5 - subdir");
Modified: trunk/jwebunit-commons-tests/src/main/java/net/sourceforge/jwebunit/tests/JUnitPerfTest.java
===================================================================
--- trunk/jwebunit-commons-tests/src/main/java/net/sourceforge/jwebunit/tests/JUnitPerfTest.java 2010-10-18 09:48:01 UTC (rev 859)
+++ trunk/jwebunit-commons-tests/src/main/java/net/sourceforge/jwebunit/tests/JUnitPerfTest.java 2010-10-18 16:01:49 UTC (rev 860)
@@ -20,36 +20,60 @@
package net.sourceforge.jwebunit.tests;
-import com.clarkware.junitperf.ConstantTimer;
-import com.clarkware.junitperf.LoadTest;
-import com.clarkware.junitperf.TestFactory;
-import com.clarkware.junitperf.Timer;
+import static net.sourceforge.jwebunit.junit.JWebUnit.assertTitleEquals;
+import static net.sourceforge.jwebunit.junit.JWebUnit.beginAt;
+import static net.sourceforge.jwebunit.junit.JWebUnit.clickLinkWithText;
+import static net.sourceforge.jwebunit.junit.JWebUnit.setBaseUrl;
+import static org.junit.Assert.assertEquals;
+import static org.junit.Assert.fail;
+import net.sourceforge.jwebunit.tests.util.Concurrent;
+import net.sourceforge.jwebunit.tests.util.ConcurrentRule;
-import junit.framework.Test;
-import junit.framework.TestCase;
-import junit.framework.TestSuite;
+import org.junit.Rule;
+import org.junit.Test;
+import org.junit.rules.Timeout;
+
/**
* Test junit perf integration.
*
* @author Julien Henry
*/
-public class JUnitPerfTest extends TestCase {
+public class JUnitPerfTest extends JWebUnitAPITestCase {
- public static TestSuite suite() {
+ public void setUp() throws Exception {
+ super.setUp();
+ setBaseUrl(HOST_PATH + "/NavigationTest");
+ }
- // create a timed test that verifies that the called function
- // is completed in the specified time
- TestSuite suite = new TestSuite();
-
- int users = 5;
- Timer timer = new ConstantTimer(10);
- Test factory = new TestFactory(NavigationTest.class);
- Test loadTest = new LoadTest(factory, users, timer);
-
- suite.addTest(loadTest);
+ @Rule
+ public Timeout timeoutRule = new Timeout(1000);
- return suite;
+ @Rule
+ public ConcurrentRule concurrentRule = new ConcurrentRule();
+
+ @Test
+ @Concurrent(5)
+ public void testClickLinkWithTextN() {
+ beginAt("/pageWithLink.html");
+ assertTitleEquals("pageWithLink");
+
+ clickLinkWithText("an active link", 0);
+ assertTitleEquals("targetPage");
+
+ beginAt("/pageWithLink.html");
+ clickLinkWithText("an active link", 1);
+
+ assertTitleEquals("targetPage2");
+ beginAt("/pageWithLink.html");
+ try {
+ clickLinkWithText("an active link", 2);
+ fail();
+ } catch (AssertionError expected) {
+ assertEquals("Link with text [an active link] and index [2] "
+ + "not found in response.", expected.getMessage());
+ }
+ assertTitleEquals("pageWithLink");
}
}
\ No newline at end of file
Modified: trunk/jwebunit-commons-tests/src/main/java/net/sourceforge/jwebunit/tests/JWebUnitAPITestCase.java
===================================================================
--- trunk/jwebunit-commons-tests/src/main/java/net/sourceforge/jwebunit/tests/JWebUnitAPITestCase.java 2010-10-18 09:48:01 UTC (rev 859)
+++ trunk/jwebunit-commons-tests/src/main/java/net/sourceforge/jwebunit/tests/JWebUnitAPITestCase.java 2010-10-18 16:01:49 UTC (rev 860)
@@ -21,17 +21,22 @@
import java.lang.reflect.InvocationTargetException;
-import net.sourceforge.jwebunit.junit.WebTestCase;
-import net.sourceforge.jwebunit.junit.WebTester;
-import net.sourceforge.jwebunit.tests.util.reflect.MethodInvoker;
+import org.junit.After;
+import org.junit.Before;
+import net.sourceforge.jwebunit.junit.JWebUnit;
+import net.sourceforge.jwebunit.tests.util.reflect.StaticMethodInvoker;
+
+import static net.sourceforge.jwebunit.junit.JWebUnit.*;
+import static org.junit.Assert.*;
+
/**
* This class is intended be used by all "testcase" classes that are used to test the functionality of the jwebunit core
* api. This isn't to be extended by end users of the jwebunit api.
*
* @author Nicholas Neuberger
*/
-public abstract class JWebUnitAPITestCase extends WebTestCase {
+public abstract class JWebUnitAPITestCase {
protected static final Object[] NOARGS = new Object[0];
@@ -42,29 +47,16 @@
public static final String HOST_PATH = "http://localhost:" + JETTY_PORT
+ JETTY_URL;
- public JWebUnitAPITestCase(String name, WebTester custom) {
- super(name, custom);
- }
-
- /**
- * @param name
- */
- public JWebUnitAPITestCase(String name) {
- super(name);
- }
-
- /**
- *
- */
- public JWebUnitAPITestCase() {
- super();
- }
-
+ @Before
public void setUp() throws Exception {
- super.setUp();
getTestContext().setBaseUrl(HOST_PATH);
getTestContext().setAuthorization("admin", "admin");
}
+
+ @After
+ public void closeBrowser() {
+ JWebUnit.closeBrowser();
+ }
public void assertPassFail(String methodName, Object passArg,
Object failArgs) throws Throwable {
@@ -84,7 +76,7 @@
protected void assertPass(String methodName, Object[] args)
throws Throwable {
- MethodInvoker invoker = new MethodInvoker(this, methodName, args);
+ StaticMethodInvoker invoker = new StaticMethodInvoker(JWebUnit.class, methodName, args);
try {
invoker.invoke();
} catch (InvocationTargetException e) {
@@ -102,7 +94,7 @@
public void assertException(Class<?> exceptionClass, String methodName,
Object[] args) {
- MethodInvoker invoker = new MethodInvoker(this, methodName, args);
+ StaticMethodInvoker invoker = new StaticMethodInvoker(JWebUnit.class, methodName, args);
try {
invoker.invoke();
fail("Expected test failure did not occur for method: "
Modified: trunk/jwebunit-commons-tests/src/main/java/net/sourceforge/jwebunit/tests/JavaScriptEventsTest.java
===================================================================
--- trunk/jwebunit-commons-tests/src/main/java/net/sourceforge/jwebunit/tests/JavaScriptEventsTest.java 2010-10-18 09:48:01 UTC (rev 859)
+++ trunk/jwebunit-commons-tests/src/main/java/net/sourceforge/jwebunit/tests/JavaScriptEventsTest.java 2010-10-18 16:01:49 UTC (rev 860)
@@ -20,10 +20,25 @@
package net.sourceforge.jwebunit.tests;
-import junit.framework.Test;
-import junit.framework.TestSuite;
-import net.sourceforge.jwebunit.tests.util.JettySetup;
+import static net.sourceforge.jwebunit.junit.JWebUnit.assertButtonPresent;
+import static net.sourceforge.jwebunit.junit.JWebUnit.assertTextFieldEquals;
+import static net.sourceforge.jwebunit.junit.JWebUnit.assertTextNotPresent;
+import static net.sourceforge.jwebunit.junit.JWebUnit.assertTextPresent;
+import static net.sourceforge.jwebunit.junit.JWebUnit.assertTitleEquals;
+import static net.sourceforge.jwebunit.junit.JWebUnit.beginAt;
+import static net.sourceforge.jwebunit.junit.JWebUnit.clickButton;
+import static net.sourceforge.jwebunit.junit.JWebUnit.clickLink;
+import static net.sourceforge.jwebunit.junit.JWebUnit.clickLinkWithText;
+import static net.sourceforge.jwebunit.junit.JWebUnit.gotoWindow;
+import static net.sourceforge.jwebunit.junit.JWebUnit.reset;
+import static net.sourceforge.jwebunit.junit.JWebUnit.selectOption;
+import static net.sourceforge.jwebunit.junit.JWebUnit.setBaseUrl;
+import static net.sourceforge.jwebunit.junit.JWebUnit.setScriptingEnabled;
+import static net.sourceforge.jwebunit.junit.JWebUnit.setWorkingForm;
+import static net.sourceforge.jwebunit.junit.JWebUnit.submit;
+import org.junit.Test;
+
/**
* User: djoiner
* Date: Nov 22, 2002
@@ -32,31 +47,26 @@
public class JavaScriptEventsTest extends JWebUnitAPITestCase {
- public static Test suite() {
- Test suite = new TestSuite(JavaScriptEventsTest.class);
- return new JettySetup(suite);
- }
-
public void setUp() throws Exception {
super.setUp();
setBaseUrl(HOST_PATH + "/JavaScriptEventsTest");
}
- public void testFormOnSubmit() {
+ @Test public void testFormOnSubmit() {
beginAt("FormOnSubmit.html");
submit();
gotoWindow("child");
assertTextPresent("on=submit");
}
- public void testFormOnReset() {
+ @Test public void testFormOnReset() {
beginAt("FormOnSubmit.html");
reset();
gotoWindow("child");
assertTextPresent("on=reset");
}
- public void testButtonOnClick() {
+ @Test public void testButtonOnClick() {
beginAt("FormOnSubmit.html");
assertButtonPresent("b1");
clickButton("b1");
@@ -65,14 +75,14 @@
}
- public void testJavaScriptInFile() {
+ @Test public void testJavaScriptInFile() {
beginAt("index.html");
assertTitleEquals("Startpage");
clickButton("next");
assertTextPresent("Here is the text we expect");
}
- public void testLinkAssertsWorkJavascriptDisabled() {
+ @Test public void testLinkAssertsWorkJavascriptDisabled() {
setScriptingEnabled(false);
beginAt(...
[truncated message content] |
|
From: Julien H. <he...@ya...> - 2010-10-18 10:35:18
|
Hi again, For those wanting to test JWebUnit 2.5-SNAPSHOT before the release, you can use this repository: https://oss.sonatype.org/content/repositories/snapshots Regards, Julien |
|
From: <he...@us...> - 2010-10-18 09:48:07
|
Revision: 859
http://jwebunit.svn.sourceforge.net/jwebunit/?rev=859&view=rev
Author: henryju
Date: 2010-10-18 09:48:01 +0000 (Mon, 18 Oct 2010)
Log Message:
-----------
Updated versions in documentation for the 2.5 release.
Modified Paths:
--------------
branches/2.x/README.txt
branches/2.x/jwebunit-htmlunit-plugin/src/site/xdoc/index.xml
branches/2.x/jwebunit-selenium-plugin/src/site/xdoc/index.xml
branches/2.x/src/changes/changes.xml
branches/2.x/src/site/xdoc/index.xml
branches/2.x/src/site/xdoc/installation.xml
Modified: branches/2.x/README.txt
===================================================================
--- branches/2.x/README.txt 2010-10-18 09:41:18 UTC (rev 858)
+++ branches/2.x/README.txt 2010-10-18 09:48:01 UTC (rev 859)
@@ -1,4 +1,4 @@
-The JWebUnit team is pleased to announce the JWebUnit 2.4 release!
+The JWebUnit team is pleased to announce the JWebUnit 2.5 release!
http://jwebunit.sourceforge.net
Modified: branches/2.x/jwebunit-htmlunit-plugin/src/site/xdoc/index.xml
===================================================================
--- branches/2.x/jwebunit-htmlunit-plugin/src/site/xdoc/index.xml 2010-10-18 09:41:18 UTC (rev 858)
+++ branches/2.x/jwebunit-htmlunit-plugin/src/site/xdoc/index.xml 2010-10-18 09:48:01 UTC (rev 859)
@@ -111,7 +111,7 @@
<dependency>
<groupId>net.sourceforge.jwebunit</groupId>
<artifactId>jwebunit-htmlunit-plugin</artifactId>
- <version>2.0</version>
+ <version>2.5</version>
</dependency>
...
</dependencies>
Modified: branches/2.x/jwebunit-selenium-plugin/src/site/xdoc/index.xml
===================================================================
--- branches/2.x/jwebunit-selenium-plugin/src/site/xdoc/index.xml 2010-10-18 09:41:18 UTC (rev 858)
+++ branches/2.x/jwebunit-selenium-plugin/src/site/xdoc/index.xml 2010-10-18 09:48:01 UTC (rev 859)
@@ -49,7 +49,7 @@
<dependency>
<groupId>net.sourceforge.jwebunit</groupId>
<artifactId>jwebunit-selenium-plugin</artifactId>
- <version>2.0</version>
+ <version>2.5</version>
</dependency>
...
</dependencies>
Modified: branches/2.x/src/changes/changes.xml
===================================================================
--- branches/2.x/src/changes/changes.xml 2010-10-18 09:41:18 UTC (rev 858)
+++ branches/2.x/src/changes/changes.xml 2010-10-18 09:48:01 UTC (rev 859)
@@ -31,7 +31,7 @@
</author>
</properties>
<body>
- <release version="2.5" date="UNKNOW" description="">
+ <release version="2.5" date="October 18, 2010" description="Small fixes and dependency updates">
<action type="update" dev="henryju">
Updated to slf4j 1.6.1.
</action>
Modified: branches/2.x/src/site/xdoc/index.xml
===================================================================
--- branches/2.x/src/site/xdoc/index.xml 2010-10-18 09:41:18 UTC (rev 858)
+++ branches/2.x/src/site/xdoc/index.xml 2010-10-18 09:48:01 UTC (rev 859)
@@ -55,7 +55,7 @@
</p>
<p>
- The current version of JWebUnit is 2.4. This is the "stable" version of
+ The current version of JWebUnit is 2.5. This is the "stable" version of
JWebUnit, and requires Java 1.5.
</p>
</section>
Modified: branches/2.x/src/site/xdoc/installation.xml
===================================================================
--- branches/2.x/src/site/xdoc/installation.xml 2010-10-18 09:41:18 UTC (rev 858)
+++ branches/2.x/src/site/xdoc/installation.xml 2010-10-18 09:48:01 UTC (rev 859)
@@ -43,7 +43,7 @@
<dependency>
<groupId>net.sourceforge.jwebunit</groupId>
<artifactId>jwebunit-htmlunit-plugin</artifactId>
- <version>2.2</version>
+ <version>2.5</version>
<scope>test</scope>
</dependency>
</dependencies>
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <he...@us...> - 2010-10-18 09:41:25
|
Revision: 858
http://jwebunit.svn.sourceforge.net/jwebunit/?rev=858&view=rev
Author: henryju
Date: 2010-10-18 09:41:18 +0000 (Mon, 18 Oct 2010)
Log Message:
-----------
Updated trunk to version 3.0-SNAPSHOT
Modified Paths:
--------------
trunk/jwebunit-commons-tests/pom.xml
trunk/jwebunit-core/pom.xml
trunk/jwebunit-htmlunit-plugin/pom.xml
trunk/jwebunit-selenium-plugin/pom.xml
trunk/jwebunit-webtestcase-generator/pom.xml
trunk/pom.xml
trunk/src/changes/changes.xml
Modified: trunk/jwebunit-commons-tests/pom.xml
===================================================================
--- trunk/jwebunit-commons-tests/pom.xml 2010-10-18 09:33:38 UTC (rev 857)
+++ trunk/jwebunit-commons-tests/pom.xml 2010-10-18 09:41:18 UTC (rev 858)
@@ -2,7 +2,7 @@
<parent>
<artifactId>jwebunit</artifactId>
<groupId>net.sourceforge.jwebunit</groupId>
- <version>2.5-SNAPSHOT</version>
+ <version>3.0-SNAPSHOT</version>
<relativePath>../pom.xml</relativePath>
</parent>
<modelVersion>4.0.0</modelVersion>
Modified: trunk/jwebunit-core/pom.xml
===================================================================
--- trunk/jwebunit-core/pom.xml 2010-10-18 09:33:38 UTC (rev 857)
+++ trunk/jwebunit-core/pom.xml 2010-10-18 09:41:18 UTC (rev 858)
@@ -2,7 +2,7 @@
<parent>
<artifactId>jwebunit</artifactId>
<groupId>net.sourceforge.jwebunit</groupId>
- <version>2.5-SNAPSHOT</version>
+ <version>3.0-SNAPSHOT</version>
<relativePath>../pom.xml</relativePath>
</parent>
<modelVersion>4.0.0</modelVersion>
Modified: trunk/jwebunit-htmlunit-plugin/pom.xml
===================================================================
--- trunk/jwebunit-htmlunit-plugin/pom.xml 2010-10-18 09:33:38 UTC (rev 857)
+++ trunk/jwebunit-htmlunit-plugin/pom.xml 2010-10-18 09:41:18 UTC (rev 858)
@@ -2,7 +2,7 @@
<parent>
<artifactId>jwebunit</artifactId>
<groupId>net.sourceforge.jwebunit</groupId>
- <version>2.5-SNAPSHOT</version>
+ <version>3.0-SNAPSHOT</version>
<relativePath>../pom.xml</relativePath>
</parent>
<modelVersion>4.0.0</modelVersion>
Modified: trunk/jwebunit-selenium-plugin/pom.xml
===================================================================
--- trunk/jwebunit-selenium-plugin/pom.xml 2010-10-18 09:33:38 UTC (rev 857)
+++ trunk/jwebunit-selenium-plugin/pom.xml 2010-10-18 09:41:18 UTC (rev 858)
@@ -2,7 +2,7 @@
<parent>
<artifactId>jwebunit</artifactId>
<groupId>net.sourceforge.jwebunit</groupId>
- <version>2.5-SNAPSHOT</version>
+ <version>3.0-SNAPSHOT</version>
<relativePath>../pom.xml</relativePath>
</parent>
<modelVersion>4.0.0</modelVersion>
Modified: trunk/jwebunit-webtestcase-generator/pom.xml
===================================================================
--- trunk/jwebunit-webtestcase-generator/pom.xml 2010-10-18 09:33:38 UTC (rev 857)
+++ trunk/jwebunit-webtestcase-generator/pom.xml 2010-10-18 09:41:18 UTC (rev 858)
@@ -2,7 +2,7 @@
<parent>
<artifactId>jwebunit</artifactId>
<groupId>net.sourceforge.jwebunit</groupId>
- <version>2.5-SNAPSHOT</version>
+ <version>3.0-SNAPSHOT</version>
<relativePath>../pom.xml</relativePath>
</parent>
<modelVersion>4.0.0</modelVersion>
Modified: trunk/pom.xml
===================================================================
--- trunk/pom.xml 2010-10-18 09:33:38 UTC (rev 857)
+++ trunk/pom.xml 2010-10-18 09:41:18 UTC (rev 858)
@@ -4,7 +4,7 @@
<groupId>net.sourceforge.jwebunit</groupId>
<artifactId>jwebunit</artifactId>
<name>JWebUnit</name>
- <version>2.5-SNAPSHOT</version>
+ <version>3.0-SNAPSHOT</version>
<packaging>pom</packaging>
<description>
JWebUnit is a Java framework that facilitates creation of
Modified: trunk/src/changes/changes.xml
===================================================================
--- trunk/src/changes/changes.xml 2010-10-18 09:33:38 UTC (rev 857)
+++ trunk/src/changes/changes.xml 2010-10-18 09:41:18 UTC (rev 858)
@@ -35,6 +35,8 @@
<action type="update" dev="henryju">
Updated to JUnit 4. See migration section of the documentation.
</action>
+ </release>
+ <release version="2.5" date="UNKNOW" description="Small fixes and dependency updates">
<action type="update" dev="henryju">
Updated to slf4j 1.6.1.
</action>
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <he...@us...> - 2010-10-18 09:33:44
|
Revision: 857
http://jwebunit.svn.sourceforge.net/jwebunit/?rev=857&view=rev
Author: henryju
Date: 2010-10-18 09:33:38 +0000 (Mon, 18 Oct 2010)
Log Message:
-----------
Created a branch for 2.x (pre JUnit 4 migration)
Added Paths:
-----------
branches/2.x/
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <he...@us...> - 2010-10-18 09:32:36
|
Revision: 856
http://jwebunit.svn.sourceforge.net/jwebunit/?rev=856&view=rev
Author: henryju
Date: 2010-10-18 09:32:30 +0000 (Mon, 18 Oct 2010)
Log Message:
-----------
Branches cleanup.
Removed Paths:
-------------
branches/1.x/
branches/2.x/
branches/JACOBIE/
branches/experimental/
branches/jwebunit-1.4.x/
branches/rc1/
branches/release_1_2/
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: Julien H. <he...@ya...> - 2010-10-18 09:27:11
|
Hi all,
I'm working on JUnit 4 migration (we are already depending on junit-4.jar but
still using old JUnit 3 style/api).
I plan to keep old WebTestCase for those still using JUnit 3, and create a new
class called JWebUnit (do you have a better suggestion?). JWebUnit class will
contains the same things than WebTestCase but followin JUnit 4 way, all methods
will be static in order to allow writing tests this way:
import static net.sourceforge.jwebunit.junit.JWebUnit.*;
public class MyTest {
@Test
public void aTest() {
beginAt("http://google.com");
...
}
}
I will also update all JWebUnit internal tests to use this new syntax.
After this work is done, I suggest to release a version 3.0.
I will still try to release a 2.5 with pre JUnit 4 migration work.
If you have any suggestion, feel free to tell me.
Regards,
Julien
|
|
From: <he...@us...> - 2010-10-18 09:17:15
|
Revision: 855
http://jwebunit.svn.sourceforge.net/jwebunit/?rev=855&view=rev
Author: henryju
Date: 2010-10-18 09:17:06 +0000 (Mon, 18 Oct 2010)
Log Message:
-----------
JUnit 4 migration part 1: migrated WebTester to JUnit 4 (and updated tests and documentation accordingly).
Modified Paths:
--------------
trunk/jwebunit-commons-tests/src/main/java/net/sourceforge/jwebunit/tests/FormSubmissionTest.java
trunk/jwebunit-commons-tests/src/main/java/net/sourceforge/jwebunit/tests/IElementTest.java
trunk/jwebunit-commons-tests/src/main/java/net/sourceforge/jwebunit/tests/JWebUnitAPITestCase.java
trunk/jwebunit-commons-tests/src/main/java/net/sourceforge/jwebunit/tests/NavigationTest.java
trunk/jwebunit-commons-tests/src/main/java/net/sourceforge/jwebunit/tests/WebAssertionsTest.java
trunk/jwebunit-core/src/main/java/net/sourceforge/jwebunit/junit/WebTester.java
trunk/src/changes/changes.xml
trunk/src/site/site.xml
Added Paths:
-----------
trunk/src/site/xdoc/migration.xml
Modified: trunk/jwebunit-commons-tests/src/main/java/net/sourceforge/jwebunit/tests/FormSubmissionTest.java
===================================================================
--- trunk/jwebunit-commons-tests/src/main/java/net/sourceforge/jwebunit/tests/FormSubmissionTest.java 2010-10-18 09:11:31 UTC (rev 854)
+++ trunk/jwebunit-commons-tests/src/main/java/net/sourceforge/jwebunit/tests/FormSubmissionTest.java 2010-10-18 09:17:06 UTC (rev 855)
@@ -26,7 +26,6 @@
import java.io.IOException;
import net.sourceforge.jwebunit.tests.util.JettySetup;
-import junit.framework.AssertionFailedError;
import junit.framework.Test;
import junit.framework.TestSuite;
@@ -198,10 +197,10 @@
gotoMultiButtonPage();
try {
setTextField("nonexistent", "anyvalue");
- } catch (AssertionFailedError e) {
- return;
+ fail("Expected AssertionError");
+ } catch (AssertionError e) {
+ //OK it was expected
}
- fail("Expected AssertionFailedError");
}
public void testParamSetOnMultiForm() {
Modified: trunk/jwebunit-commons-tests/src/main/java/net/sourceforge/jwebunit/tests/IElementTest.java
===================================================================
--- trunk/jwebunit-commons-tests/src/main/java/net/sourceforge/jwebunit/tests/IElementTest.java 2010-10-18 09:11:31 UTC (rev 854)
+++ trunk/jwebunit-commons-tests/src/main/java/net/sourceforge/jwebunit/tests/IElementTest.java 2010-10-18 09:17:06 UTC (rev 855)
@@ -22,7 +22,6 @@
import java.util.Date;
import java.util.List;
-import junit.framework.AssertionFailedError;
import junit.framework.Test;
import junit.framework.TestSuite;
import net.sourceforge.jwebunit.api.IElement;
@@ -61,7 +60,7 @@
try {
getElementByXPath("//input[@id='test2']");
fail("getElementByXPath() should have thrown an assertion exception.");
- } catch (AssertionFailedError e) {
+ } catch (AssertionError e) {
// nothing
}
}
Modified: trunk/jwebunit-commons-tests/src/main/java/net/sourceforge/jwebunit/tests/JWebUnitAPITestCase.java
===================================================================
--- trunk/jwebunit-commons-tests/src/main/java/net/sourceforge/jwebunit/tests/JWebUnitAPITestCase.java 2010-10-18 09:11:31 UTC (rev 854)
+++ trunk/jwebunit-commons-tests/src/main/java/net/sourceforge/jwebunit/tests/JWebUnitAPITestCase.java 2010-10-18 09:17:06 UTC (rev 855)
@@ -21,7 +21,6 @@
import java.lang.reflect.InvocationTargetException;
-import junit.framework.AssertionFailedError;
import net.sourceforge.jwebunit.junit.WebTestCase;
import net.sourceforge.jwebunit.junit.WebTester;
import net.sourceforge.jwebunit.tests.util.reflect.MethodInvoker;
@@ -98,7 +97,7 @@
}
public void assertFail(String methodName, Object[] args) {
- assertException(AssertionFailedError.class, methodName, args);
+ assertException(AssertionError.class, methodName, args);
}
public void assertException(Class<?> exceptionClass, String methodName,
Modified: trunk/jwebunit-commons-tests/src/main/java/net/sourceforge/jwebunit/tests/NavigationTest.java
===================================================================
--- trunk/jwebunit-commons-tests/src/main/java/net/sourceforge/jwebunit/tests/NavigationTest.java 2010-10-18 09:11:31 UTC (rev 854)
+++ trunk/jwebunit-commons-tests/src/main/java/net/sourceforge/jwebunit/tests/NavigationTest.java 2010-10-18 09:17:06 UTC (rev 855)
@@ -22,7 +22,6 @@
import net.sourceforge.jwebunit.exception.TestingEngineResponseException;
import net.sourceforge.jwebunit.tests.util.JettySetup;
-import junit.framework.AssertionFailedError;
import junit.framework.Test;
import junit.framework.TestSuite;
@@ -91,7 +90,7 @@
try {
clickLinkWithText("an active link", 2);
fail();
- } catch (AssertionFailedError expected) {
+ } catch (AssertionError expected) {
assertEquals("Link with text [an active link] and index [2] "
+ "not found in response.", expected.getMessage());
}
@@ -163,7 +162,7 @@
boolean passed = false;
try {
clickLinkWithExactText("doesn't exist");
- } catch (AssertionFailedError e) {
+ } catch (AssertionError e) {
// expected
passed = true;
}
Modified: trunk/jwebunit-commons-tests/src/main/java/net/sourceforge/jwebunit/tests/WebAssertionsTest.java
===================================================================
--- trunk/jwebunit-commons-tests/src/main/java/net/sourceforge/jwebunit/tests/WebAssertionsTest.java 2010-10-18 09:11:31 UTC (rev 854)
+++ trunk/jwebunit-commons-tests/src/main/java/net/sourceforge/jwebunit/tests/WebAssertionsTest.java 2010-10-18 09:17:06 UTC (rev 855)
@@ -19,7 +19,6 @@
package net.sourceforge.jwebunit.tests;
-import junit.framework.AssertionFailedError;
import junit.framework.Test;
import junit.framework.TestSuite;
import net.sourceforge.jwebunit.tests.util.JettySetup;
@@ -77,15 +76,13 @@
* Check that {@link #assertNoMatch(String)} can actually fail.
*/
public void testAssertNoMatchFails() throws Throwable {
- boolean failed = false;
try {
// 'Span Text' definitely exists in the source page text
assertNoMatch("Span Text");
- failed = true; // should not get this far
- } catch (AssertionFailedError e) {
+ fail("assertNoMatch() did not throw expected failure"); // should not get this far
+ } catch (AssertionError e) {
// expected
}
- assertFalse("assertNoMatch() did not throw expected failure", failed);
}
public void testAssertLinkPresentWithText() throws Throwable {
Modified: trunk/jwebunit-core/src/main/java/net/sourceforge/jwebunit/junit/WebTester.java
===================================================================
--- trunk/jwebunit-core/src/main/java/net/sourceforge/jwebunit/junit/WebTester.java 2010-10-18 09:11:31 UTC (rev 854)
+++ trunk/jwebunit-core/src/main/java/net/sourceforge/jwebunit/junit/WebTester.java 2010-10-18 09:17:06 UTC (rev 855)
@@ -41,8 +41,6 @@
import javax.imageio.ImageIO;
import javax.servlet.http.Cookie;
-import junit.framework.Assert;
-import junit.framework.AssertionFailedError;
import net.sourceforge.jwebunit.api.IElement;
import net.sourceforge.jwebunit.api.ITestingEngine;
import net.sourceforge.jwebunit.exception.ExpectedJavascriptAlertException;
@@ -60,6 +58,8 @@
import org.apache.regexp.RE;
import org.apache.regexp.RESyntaxException;
+import static org.junit.Assert.*;
+
/**
* Provides a high-level API for basic web application navigation and validation by providing
* JUnit assertions. It supports use of a property file for web resources (a la Struts), though a resource file for the
@@ -160,15 +160,15 @@
try {
getTestingEngine().closeBrowser();
} catch (ExpectedJavascriptAlertException e) {
- Assert.fail("You previously tell that alert with message ["
+ fail("You previously tell that alert with message ["
+ e.getAlertMessage()
+ "] was expected, but nothing appeared.");
} catch (ExpectedJavascriptConfirmException e) {
- Assert.fail("You previously tell that confirm with message ["
+ fail("You previously tell that confirm with message ["
+ e.getConfirmMessage()
+ "] was expected, but nothing appeared.");
} catch (ExpectedJavascriptPromptException e) {
- Assert.fail("You previously tell that prompt with message ["
+ fail("You previously tell that prompt with message ["
+ e.getPromptMessage()
+ "] was expected, but nothing appeared.");
}
@@ -227,7 +227,7 @@
try {
getTestingEngine().beginAt(createUrl(aRelativeURL, getTestContext().getBaseUrl()), testContext);
} catch (MalformedURLException e) {
- Assert.fail(e.getLocalizedMessage());
+ fail(e.getLocalizedMessage());
}
}
@@ -295,7 +295,7 @@
* @param status the expected status code
*/
public void assertResponseCode(int status) {
- Assert.assertEquals( status, getTestingEngine().getServerResponseCode() );
+ assertEquals( status, getTestingEngine().getServerResponseCode() );
}
/**
@@ -306,7 +306,7 @@
* @param higher the upper bound for the expected status code
*/
public void assertResponseCodeBetween(int lower, int higher) {
- Assert.assertTrue( getTestingEngine().getServerResponseCode() >= lower && getTestingEngine().getServerResponseCode() <= higher );
+ assertTrue( getTestingEngine().getServerResponseCode() >= lower && getTestingEngine().getServerResponseCode() <= higher );
}
/**
@@ -325,7 +325,7 @@
* @param name The header to find
*/
public void assertHeaderPresent(String name) {
- Assert.assertFalse( "header '" + name + "' not present", getTestingEngine().getHeader(name) == null );
+ assertFalse( "header '" + name + "' not present", getTestingEngine().getHeader(name) == null );
}
/**
@@ -334,7 +334,7 @@
* @param name The header to find
*/
public void assertHeaderNotPresent(String name) {
- Assert.assertTrue( "header '" + name + "' present", getTestingEngine().getHeader(name) == null );
+ assertTrue( "header '" + name + "' present", getTestingEngine().getHeader(name) == null );
}
/**
@@ -344,7 +344,7 @@
* @param value Value to compare against
*/
public void assertHeaderEquals(String name, String value) {
- Assert.assertEquals( value, getTestingEngine().getHeader(name) );
+ assertEquals( value, getTestingEngine().getHeader(name) );
}
/**
@@ -384,7 +384,7 @@
* expected title value
*/
public void assertTitleEquals(String title) {
- Assert.assertEquals(title, getTestingEngine().getPageTitle());
+ assertEquals(title, getTestingEngine().getPageTitle());
}
/**
@@ -395,7 +395,7 @@
* unexpected title value
*/
public void assertTitleNotSame(String title) {
- Assert.assertNotSame(title, getTestingEngine().getPageTitle());
+ assertNotSame(title, getTestingEngine().getPageTitle());
}
/**
@@ -415,7 +415,7 @@
* web resource key for title
*/
public void assertTitleEqualsKey(String titleKey) {
- Assert.assertEquals(getMessage(titleKey), getTestingEngine().getPageTitle());
+ assertEquals(getMessage(titleKey), getTestingEngine().getPageTitle());
}
/**
@@ -425,7 +425,7 @@
* @param args
*/
public void assertTitleEqualsKey(String titleKey, Object[] args) {
- Assert.assertEquals(getMessage(titleKey, args), getTestingEngine().getPageTitle());
+ assertEquals(getMessage(titleKey, args), getTestingEngine().getPageTitle());
}
/**
@@ -455,7 +455,7 @@
*/
public void assertTextPresent(String text) {
if (!(getTestingEngine().getPageText().contains(text)))
- Assert.fail("Expected text not found in current page: [" + text
+ fail("Expected text not found in current page: [" + text
+ "]\n Page content was: ["
+ getTestingEngine().getPageText() + "]");
}
@@ -468,7 +468,7 @@
public void assertMatch(String regexp) {
RE re = getRE(regexp);
if (!re.match(getTestingEngine().getPageText()))
- Assert.fail("Expected rexexp not matched in response: [" + regexp
+ fail("Expected rexexp not matched in response: [" + regexp
+ "]");
}
@@ -502,7 +502,7 @@
public void assertMatch(String message, String regexp, String text) {
RE re = getRE(regexp);
if (!re.match(text))
- Assert.fail(message);
+ fail(message);
}
/**
@@ -514,7 +514,7 @@
public void assertNotMatch(String message, String regexp, String text) {
RE re = getRE(regexp);
if (re.match(text))
- Assert.fail(message);
+ fail(message);
}
/**
@@ -543,7 +543,7 @@
*/
public void assertTextNotPresent(String text) {
if (getTestingEngine().getPageText().contains(text))
- Assert.fail("Text found in response when not expected: [" + text
+ fail("Text found in response when not expected: [" + text
+ "]");
}
@@ -574,7 +574,7 @@
*/
public void assertTablePresent(String tableSummaryNameOrId) {
if (!getTestingEngine().hasTable(tableSummaryNameOrId))
- Assert.fail("Unable to locate table \"" + tableSummaryNameOrId
+ fail("Unable to locate table \"" + tableSummaryNameOrId
+ "\"");
}
@@ -585,7 +585,7 @@
*/
public void assertTableNotPresent(String tableSummaryNameOrId) {
if (getTestingEngine().hasTable(tableSummaryNameOrId))
- Assert.fail("Located table \"" + tableSummaryNameOrId + "\"");
+ fail("Located table \"" + tableSummaryNameOrId + "\"");
}
/**
@@ -620,7 +620,7 @@
*/
public void assertTextInTable(String tableSummaryNameOrId, String text) {
assertTablePresent(tableSummaryNameOrId);
- Assert.assertTrue("Could not find: [" + text + "]" + "in table ["
+ assertTrue("Could not find: [" + text + "]" + "in table ["
+ tableSummaryNameOrId + "]", getTestingEngine().getTable(
tableSummaryNameOrId).hasText(text));
}
@@ -633,7 +633,7 @@
*/
public void assertMatchInTable(String tableSummaryNameOrId, String regexp) {
assertTablePresent(tableSummaryNameOrId);
- Assert.assertTrue("Could not match: [" + regexp + "]" + "in table ["
+ assertTrue("Could not match: [" + regexp + "]" + "in table ["
+ tableSummaryNameOrId + "]", getTestingEngine().getTable(
tableSummaryNameOrId).hasMatch(regexp));
}
@@ -709,7 +709,7 @@
*/
public void assertTextNotInTable(String tableSummaryNameOrId, String text) {
assertTablePresent(tableSummaryNameOrId);
- Assert.assertTrue("Found text: [" + text + "] in table ["
+ assertTrue("Found text: [" + text + "] in table ["
+ tableSummaryNameOrId + "]", !getTestingEngine().getTable(
tableSummaryNameOrId).hasText(text));
}
@@ -734,7 +734,7 @@
*/
public void assertNoMatchInTable(String tableSummaryNameOrId, String regexp) {
assertTablePresent(tableSummaryNameOrId);
- Assert.assertTrue("Found regexp: [" + regexp + "] in table ["
+ assertTrue("Found regexp: [" + regexp + "] in table ["
+ tableSummaryNameOrId + "]", !getTestingEngine().getTable(
tableSummaryNameOrId).hasMatch(regexp));
}
@@ -813,7 +813,7 @@
assertTablePresent(tableSummaryNameOrId);
int actualRowCount = getTestingEngine().getTable(tableSummaryNameOrId)
.getRowCount();
- Assert.assertTrue("Expected row count was " + expectedRowCount
+ assertTrue("Expected row count was " + expectedRowCount
+ " but actual row count is " + actualRowCount,
actualRowCount == expectedRowCount);
}
@@ -873,7 +873,7 @@
* @param formElementName
*/
public void assertFormElementPresent(String formElementName) {
- Assert.assertTrue("Did not find form element with name ["
+ assertTrue("Did not find form element with name ["
+ formElementName + "].", getTestingEngine()
.hasFormParameterNamed(formElementName));
}
@@ -885,7 +885,7 @@
*/
public void assertFormElementNotPresent(String formElementName) {
try {
- Assert.assertTrue("Found form element with name ["
+ assertTrue("Found form element with name ["
+ formElementName + "] when not expected.", !getTestingEngine()
.hasFormParameterNamed(formElementName));
} catch (UnableToSetFormException e) {
@@ -899,7 +899,7 @@
* @param checkboxName checkbox name.
*/
public void assertCheckboxPresent(String checkboxName) {
- Assert.assertTrue("Did not find form checkbox with name ["
+ assertTrue("Did not find form checkbox with name ["
+ checkboxName + "].", getTestingEngine().hasElementByXPath(
"//input[lower-case(@type)='checkbox' and @name='" + checkboxName + "']"));
}
@@ -911,7 +911,7 @@
* @param checkboxValue checkbox value attribut.
*/
public void assertCheckboxPresent(String checkboxName, String checkboxValue) {
- Assert.assertTrue("Did not find form checkbox with name ["
+ assertTrue("Did not find form checkbox with name ["
+ checkboxName + "] and value [" + checkboxValue + "].",
getTestingEngine().hasElementByXPath(
"//input[lower-case(@type)='checkbox' and @name='" + checkboxName
@@ -924,7 +924,7 @@
* @param checkboxName checkbox name.
*/
public void assertCheckboxNotPresent(String checkboxName) {
- Assert.assertFalse("Found form checkbox with name [" + checkboxName
+ assertFalse("Found form checkbox with name [" + checkboxName
+ "] when not expected.", getTestingEngine().hasElementByXPath(
"//input[lower-case(@type)='checkbox' and @name='" + checkboxName + "']"));
}
@@ -937,7 +937,7 @@
*/
public void assertCheckboxNotPresent(String checkboxName,
String checkboxValue) {
- Assert.assertFalse("Found form checkbox with name [" + checkboxName
+ assertFalse("Found form checkbox with name [" + checkboxName
+ "] and value [" + checkboxValue + "] when not expected.",
getTestingEngine().hasElementByXPath(
"//input[lower-case(@type)='checkbox' and @name='" + checkboxName
@@ -949,7 +949,7 @@
*
*/
public void assertFormPresent() {
- Assert.assertTrue("No form present", getTestingEngine().hasForm());
+ assertTrue("No form present", getTestingEngine().hasForm());
}
/**
@@ -958,7 +958,7 @@
* @param nameOrID
*/
public void assertFormPresent(String nameOrID) {
- Assert.assertTrue("No form present with name or id [" + nameOrID + "]",
+ assertTrue("No form present with name or id [" + nameOrID + "]",
getTestingEngine().hasForm(nameOrID));
}
@@ -967,7 +967,7 @@
*
*/
public void assertFormNotPresent() {
- Assert.assertFalse("A form is present", getTestingEngine().hasForm());
+ assertFalse("A form is present", getTestingEngine().hasForm());
}
/**
@@ -976,7 +976,7 @@
* @param nameOrID
*/
public void assertFormNotPresent(String nameOrID) {
- Assert.assertFalse("Form present with name or id [" + nameOrID + "]",
+ assertFalse("Form present with name or id [" + nameOrID + "]",
getTestingEngine().hasForm(nameOrID));
}
@@ -991,7 +991,7 @@
public void assertFormElementEquals(String formElementName,
String expectedValue) {
assertFormElementPresent(formElementName);
- Assert.assertEquals(expectedValue, getTestingEngine()
+ assertEquals(expectedValue, getTestingEngine()
.getElementAttributByXPath(
"//input[@name='" + formElementName + "']", "value"));
}
@@ -1009,9 +1009,9 @@
try {
re = new RE(regexp, RE.MATCH_SINGLELINE);
} catch (RESyntaxException e) {
- Assert.fail(e.toString());
+ fail(e.toString());
}
- Assert.assertTrue("Unable to match [" + regexp + "] in form element \""
+ assertTrue("Unable to match [" + regexp + "] in form element \""
+ formElementName + "\"", re.match(getTestingEngine()
.getElementAttributByXPath(
"//input[@name='" + formElementName + "']", "value")));
@@ -1027,7 +1027,7 @@
*/
public void assertFormElementEmpty(String formElementName) {
assertFormElementPresent(formElementName);
- Assert.assertEquals("", getTestingEngine().getElementAttributByXPath(
+ assertEquals("", getTestingEngine().getElementAttributByXPath(
"//input[@name='" + formElementName + "']", "value"));
}
@@ -1041,7 +1041,7 @@
public void assertTextFieldEquals(String formElementName,
String expectedValue) {
assertFormElementPresent(formElementName);
- Assert.assertEquals(expectedValue, getTestingEngine()
+ assertEquals(expectedValue, getTestingEngine()
.getTextFieldValue(formElementName));
}
@@ -1055,7 +1055,7 @@
public void assertHiddenFieldPresent(String formElementName,
String expectedValue) {
assertFormElementPresent(formElementName);
- Assert.assertEquals(expectedValue, getTestingEngine()
+ assertEquals(expectedValue, getTestingEngine()
.getHiddenFieldValue(formElementName));
}
@@ -1067,7 +1067,7 @@
public void assertCheckboxSelected(String checkBoxName) {
assertCheckboxPresent(checkBoxName);
if (!getTestingEngine().isCheckboxSelected(checkBoxName)) {
- Assert.fail("Checkbox with name [" + checkBoxName
+ fail("Checkbox with name [" + checkBoxName
+ "] was not found selected.");
}
}
@@ -1081,7 +1081,7 @@
public void assertCheckboxSelected(String checkBoxName, String checkBoxValue) {
assertCheckboxPresent(checkBoxName, checkBoxValue);
if (!getTestingEngine().isCheckboxSelected(checkBoxName, checkBoxValue)) {
- Assert.fail("Checkbox with name [" + checkBoxName + "] and value ["
+ fail("Checkbox with name [" + checkBoxName + "] and value ["
+ checkBoxValue + "] was not found selected.");
}
}
@@ -1094,7 +1094,7 @@
public void assertCheckboxNotSelected(String checkBoxName) {
assertCheckboxPresent(checkBoxName);
if (getTestingEngine().isCheckboxSelected(checkBoxName)) {
- Assert.fail("Checkbox with name [" + checkBoxName
+ fail("Checkbox with name [" + checkBoxName
+ "] was found selected.");
}
}
@@ -1109,7 +1109,7 @@
String checkBoxValue) {
assertCheckboxPresent(checkBoxName, checkBoxValue);
if (getTestingEngine().isCheckboxSelected(checkBoxName, checkBoxValue)) {
- Assert.fail("Checkbox with name [" + checkBoxName + "] and value ["
+ fail("Checkbox with name [" + checkBoxName + "] and value ["
+ checkBoxValue + "] was found selected.");
}
}
@@ -1123,7 +1123,7 @@
public void assertRadioOptionPresent(String name, String radioOption) {
assertFormElementPresent(name);
if (!getTestingEngine().hasRadioOption(name, radioOption)) {
- Assert.fail("Unable to find option [" + radioOption
+ fail("Unable to find option [" + radioOption
+ "] in radio group [" + name + "]");
}
}
@@ -1137,7 +1137,7 @@
public void assertRadioOptionNotPresent(String name, String radioOption) {
assertFormElementPresent(name);
if (getTestingEngine().hasRadioOption(name, radioOption))
- Assert.fail("Found option [" + radioOption + "] in radio group ["
+ fail("Found option [" + radioOption + "] in radio group ["
+ name + "]");
}
@@ -1149,7 +1149,7 @@
*/
public void assertRadioOptionSelected(String name, String radioOption) {
assertRadioOptionPresent(name, radioOption);
- Assert.assertEquals(radioOption, getTestingEngine()
+ assertEquals(radioOption, getTestingEngine()
.getSelectedRadio(name));
}
@@ -1161,7 +1161,7 @@
*/
public void assertRadioOptionNotSelected(String name, String radioOption) {
assertRadioOptionPresent(name, radioOption);
- Assert.assertFalse("Radio option [" + radioOption + "] is selected.",
+ assertFalse("Radio option [" + radioOption + "] is selected.",
radioOption.equals(getTestingEngine()
.getSelectedRadio(name)));
}
@@ -1176,7 +1176,7 @@
String[] optionLabels) {
assertFormElementPresent(selectName);
for (int i = 0; i < optionLabels.length; i++)
- Assert.assertTrue("Option [" + optionLabels[i]
+ assertTrue("Option [" + optionLabels[i]
+ "] not found in select element " + selectName,
getTestingEngine().hasSelectOption(selectName,
optionLabels[i]));
@@ -1204,7 +1204,7 @@
String[] optionLabels) {
assertFormElementPresent(selectName);
for (int i = 0; i < optionLabels.length; i++)
- Assert.assertTrue("Option [" + optionLabels[i]
+ assertTrue("Option [" + optionLabels[i]
+ "] not found in select element " + selectName,
getTestingEngine().hasSelectOption(selectName, index,
optionLabels[i]));
@@ -1233,7 +1233,7 @@
String[] optionValues) {
assertFormElementPresent(selectName);
for (int i = 0; i < optionValues.length; i++)
- Assert.assertTrue("Option [" + optionValues[i]
+ assertTrue("Option [" + optionValues[i]
+ "] not found in select element " + selectName,
getTestingEngine().hasSelectOptionValue(selectName,
optionValues[i]));
@@ -1264,7 +1264,7 @@
String[] optionValues) {
assertFormElementPresent(selectName);
for (int i = 0; i < optionValues.length; i++)
- Assert.assertTrue("Option [" + optionValues[i]
+ assertTrue("Option [" + optionValues[i]
+ "] not found in select element " + selectName,
getTestingEngine().hasSelectOptionValue(selectName,
index,
@@ -1296,10 +1296,10 @@
String optionValue) {
try {
assertSelectOptionValuePresent(selectName, optionValue);
- } catch (AssertionFailedError e) {
+ } catch (AssertionError e) {
return;
}
- Assert.fail("Option value" + optionValue + " found in select element "
+ fail("Option value" + optionValue + " found in select element "
+ selectName + " when not expected.");
}
@@ -1313,10 +1313,10 @@
String optionLabel) {
try {
assertSelectOptionPresent(selectName, optionLabel);
- } catch (AssertionFailedError e) {
+ } catch (AssertionError e) {
return;
}
- Assert.fail("Option " + optionLabel + " found in select element "
+ fail("Option " + optionLabel + " found in select element "
+ selectName + " when not expected.");
}
@@ -1330,10 +1330,10 @@
int index, String optionValue) {
try {
assertSelectOptionValuePresent(selectName, index, optionValue);
- } catch (AssertionFailedError e) {
+ } catch (AssertionError e) {
return;
}
- Assert.fail("Option value" + optionValue + " found in select element "
+ fail("Option value" + optionValue + " found in select element "
+ selectName + " when not expected.");
}
@@ -1347,10 +1347,10 @@
int index, String optionLabel) {
try {
assertSelectOptionPresent(selectName, index, optionLabel);
- } catch (AssertionFailedError e) {
+ } catch (AssertionError e) {
return;
}
- Assert.fail("Option " + optionLabel + " found in select element "
+ fail("Option " + optionLabel + " found in select element "
+ selectName + " when not expected.");
}
@@ -1393,10 +1393,10 @@
assertFormElementPresent(selectName);
try {
assertSelectOptionsEqual(selectName, expectedOptions);
- } catch (AssertionFailedError e) {
+ } catch (AssertionError e) {
return;
}
- Assert.fail("Options not expected to be equal");
+ fail("Options not expected to be equal");
}
/**
@@ -1413,10 +1413,10 @@
assertFormElementPresent(selectName);
try {
assertSelectOptionsEqual(selectName, index, expectedOptions);
- } catch (AssertionFailedError e) {
+ } catch (AssertionError e) {
return;
}
- Assert.fail("Options not expected to be equal");
+ fail("Options not expected to be equal");
}
@@ -1463,10 +1463,10 @@
assertFormElementPresent(selectName);
try {
assertSelectOptionValuesEqual(selectName, optionValues);
- } catch (AssertionFailedError e) {
+ } catch (AssertionError e) {
return;
}
- Assert.fail("Values not expected to be equal");
+ fail("Values not expected to be equal");
}
/**
@@ -1483,10 +1483,10 @@
assertFormElementPresent(selectName);
try {
assertSelectOptionValuesEqual(selectName, index, optionValues);
- } catch (AssertionFailedError e) {
+ } catch (AssertionError e) {
return;
}
- Assert.fail("Values not expected to be equal");
+ fail("Values not expected to be equal");
}
@@ -1498,10 +1498,10 @@
*/
public void assertSelectedOptionsEqual(String selectName, String[] labels) {
assertFormElementPresent(selectName);
- Assert.assertEquals(labels.length, getTestingEngine()
+ assertEquals(labels.length, getTestingEngine()
.getSelectedOptions(selectName).length);
for (int i = 0; i < labels.length; i++)
- Assert.assertEquals(labels[i],
+ assertEquals(labels[i],
getTestingEngine()
.getSelectOptionLabelForValue(
selectName,
@@ -1519,10 +1519,10 @@
*/
public void assertSelectedOptionsEqual(String selectName, int index, String[] labels) {
assertFormElementPresent(selectName);
- Assert.assertEquals(labels.length, getTestingEngine()
+ assertEquals(labels.length, getTestingEngine()
.getSelectedOptions(selectName, index).length);
for (int i = 0; i < labels.length; i++)
- Assert.assertEquals(labels[i],
+ assertEquals(labels[i],
getTestingEngine()
.getSelectOptionLabelForValue(
selectName, index,
@@ -1564,10 +1564,10 @@
public void assertSelectedOptionValuesEqual(String selectName,
String[] values) {
assertFormElementPresent(selectName);
- Assert.assertEquals(values.length, getTestingEngine()
+ assertEquals(values.length, getTestingEngine()
.getSelectedOptions(selectName).length);
for (int i = 0; i < values.length; i++)
- Assert.assertEquals(values[i], getTestingEngine()
+ assertEquals(values[i], getTestingEngine()
.getSelectedOptions(selectName)[i]);
}
@@ -1583,10 +1583,10 @@
public void assertSelectedOptionValuesEqual(String selectName,
int index, String[] values) {
assertFormElementPresent(selectName);
- Assert.assertEquals(values.length, getTestingEngine()
+ assertEquals(values.length, getTestingEngine()
.getSelectedOptions(selectName, index).length);
for (int i = 0; i < values.length; i++)
- Assert.assertEquals(values[i], getTestingEngine()
+ assertEquals(values[i], getTestingEngine()
.getSelectedOptions(selectName, index)[i]);
}
@@ -1623,11 +1623,11 @@
*/
public void assertSelectedOptionsMatch(String selectName, String[] regexps) {
assertFormElementPresent(selectName);
- Assert.assertEquals(regexps.length, getTestingEngine()
+ assertEquals(regexps.length, getTestingEngine()
.getSelectedOptions(selectName).length);
for (int i = 0; i < regexps.length; i++) {
RE re = getRE(regexps[i]);
- Assert.assertTrue("Unable to match [" + regexps[i]
+ assertTrue("Unable to match [" + regexps[i]
+ "] in option \""
+ getTestingEngine().getSelectedOptions(selectName)[i]
+ "\"", re.match(getTestingEngine().getSelectedOptions(
@@ -1645,11 +1645,11 @@
*/
public void assertSelectedOptionsMatch(String selectName, int index, String[] regexps) {
assertFormElementPresent(selectName);
- Assert.assertEquals(regexps.length, getTestingEngine()
+ assertEquals(regexps.length, getTestingEngine()
.getSelectedOptions(selectName, index).length);
for (int i = 0; i < regexps.length; i++) {
RE re = getRE(regexps[i]);
- Assert.assertTrue("Unable to match [" + regexps[i]
+ assertTrue("Unable to match [" + regexps[i]
+ "] in option \""
+ getTestingEngine().getSelectedOptions(selectName, index)[i]
+ "\" at index " + index, re.match(getTestingEngine().getSelectedOptions(
@@ -1692,7 +1692,7 @@
*
*/
public void assertSubmitButtonPresent() {
- Assert.assertTrue("no submit button found.", getTestingEngine()
+ assertTrue("no submit button found.", getTestingEngine()
.hasSubmitButton());
}
@@ -1708,7 +1708,7 @@
* @param buttonName
*/
public void assertSubmitButtonPresent(String buttonName) {
- Assert.assertTrue("Submit Button [" + buttonName + "] not found.",
+ assertTrue("Submit Button [" + buttonName + "] not found.",
getTestingEngine().hasSubmitButton(buttonName));
}
@@ -1724,7 +1724,7 @@
* @param buttonName
*/
public void assertSubmitButtonNotPresent() {
- Assert.assertFalse("Submit Button found.", getTestingEngine()
+ assertFalse("Submit Button found.", getTestingEngine()
.hasSubmitButton());
}
@@ -1740,7 +1740,7 @@
* @param buttonName
*/
public void assertSubmitButtonNotPresent(String buttonName) {
- Assert.assertFalse("Submit Button [" + buttonName + "] found.",
+ assertFalse("Submit Button [" + buttonName + "] found.",
getTestingEngine().hasSubmitButton(buttonName));
}
@@ -1757,7 +1757,7 @@
* @param buttonValue
*/
public void assertSubmitButtonPresent(String buttonName, String buttonValue) {
- Assert.assertTrue("Submit Button [" + buttonName + "] with value ["
+ assertTrue("Submit Button [" + buttonName + "] with value ["
+ buttonValue + "] not found.", getTestingEngine()
.hasSubmitButton(buttonName, buttonValue));
}
@@ -1771,7 +1771,7 @@
*
*/
public void assertResetButtonPresent() {
- Assert.assertTrue("no reset button found.", getTestingEngine()
+ assertTrue("no reset button found.", getTestingEngine()
.hasResetButton());
}
@@ -1785,7 +1785,7 @@
* @param buttonName
*/
public void assertResetButtonPresent(String buttonName) {
- Assert.assertTrue("Reset Button [" + buttonName + "] not found.",
+ assertTrue("Reset Button [" + buttonName + "] not found.",
getTestingEngine().hasResetButton(buttonName));
}
@@ -1800,7 +1800,7 @@
* @param buttonName
*/
public void assertResetButtonNotPresent() {
- Assert.assertFalse("Reset Button found.", getTestingEngine()
+ assertFalse("Reset Button found.", getTestingEngine()
.hasResetButton());
}
@@ -1815,7 +1815,7 @@
* @param buttonName
*/
public void assertResetButtonNotPresent(String buttonName) {
- Assert.assertFalse("Reset Button [" + buttonName + "] found.",
+ assertFalse("Reset Button [" + buttonName + "] found.",
getTestingEngine().hasResetButton(buttonName));
}
@@ -1830,7 +1830,7 @@
* @param buttonId
*/
public void assertButtonPresent(String buttonId) {
- Assert.assertTrue("Button [" + buttonId + "] not found.", getTestingEngine()
+ assertTrue("Button [" + buttonId + "] not found.", getTestingEngine()
.hasButton(buttonId));
}
@@ -1840,7 +1840,7 @@
* @param text Text representation of button content.
*/
public void assertButtonPresentWithText(String text) {
- Assert.assertTrue("Did not find button with text [" + text + "].",
+ assertTrue("Did not find button with text [" + text + "].",
getTestingEngine().hasButtonWithText(text));
}
@@ -1850,7 +1850,7 @@
* @param text Text representation of button content.
*/
public void assertButtonNotPresentWithText(String text) {
- Assert.assertFalse("Found button with text [" + text + "].",
+ assertFalse("Found button with text [" + text + "].",
getTestingEngine().hasButtonWithText(text));
}
@@ -1860,7 +1860,7 @@
* @param buttonId
*/
public void assertButtonNotPresent(String buttonId) {
- Assert.assertFalse(
+ assertFalse(
"Button [" + buttonId + "] found when not expected.",
getTestingEngine().hasButton(buttonId));
}
@@ -1871,7 +1871,7 @@
* @param linkId
*/
public void assertLinkPresent(String linkId) {
- Assert.assertTrue("Unable to find link with id [" + linkId + "]",
+ assertTrue("Unable to find link with id [" + linkId + "]",
getTestingEngine().hasLink(linkId));
}
@@ -1881,7 +1881,7 @@
* @param linkId
*/
public void assertLinkNotPresent(String linkId) {
- Assert.assertTrue("link with id [" + linkId + "] found in response",
+ assertTrue("link with id [" + linkId + "] found in response",
!getTestingEngine().hasLink(linkId));
}
@@ -1891,7 +1891,7 @@
* @param linkText
*/
public void assertLinkPresentWithText(String linkText) {
- Assert.assertTrue("Link with text [" + linkText
+ assertTrue("Link with text [" + linkText
+ "] not found in response.", getTestingEngine()
.hasLinkWithText(linkText, 0));
}
@@ -1902,7 +1902,7 @@
* @param linkText
*/
public void assertLinkNotPresentWithText(String linkText) {
- Assert.assertTrue("Link with text [" + linkText
+ assertTrue("Link with text [" + linkText
+ "] found in response.", !getTestingEngine().hasLinkWithText(
linkText, 0));
}
@@ -1914,7 +1914,7 @@
* @param index The 0-based index, when more than one link with the same text is expected.
*/
public void assertLinkPresentWithText(String linkText, int index) {
- Assert.assertTrue("Link with text [" + linkText + "] and index ["
+ assertTrue("Link with text [" + linkText + "] and index ["
+ index + "] not found in response.", getTestingEngine()
.hasLinkWithText(linkText, index));
}
@@ -1926,7 +1926,7 @@
* @param index The 0-based index, when more than one link with the same text is expected.
*/
public void assertLinkNotPresentWithText(String linkText, int index) {
- Assert.assertTrue("Link with text [" + linkText + "] and index "
+ assertTrue("Link with text [" + linkText + "] and index "
+ index + " found in response.", !getTestingEngine()
.hasLinkWithText(linkText, index));
}
@@ -1939,7 +1939,7 @@
* @param linkText
*/
public void assertLinkPresentWithExactText(String linkText) {
- Assert.assertTrue("Link with Exact text [" + linkText
+ assertTrue("Link with Exact text [" + linkText
+ "] not found in response.", getTestingEngine()
.hasLinkWithExactText(linkText, 0));
}
@@ -1950,7 +1950,7 @@
* @param linkText
*/
public void assertLinkNotPresentWithExactText(String linkText) {
- Assert.assertTrue("Link with Exact text [" + linkText
+ assertTrue("Link with Exact text [" + linkText
+ "] found in response.", !getTestingEngine()
.hasLinkWithExactText(linkText, 0));
}
@@ -1962,7 +1962,7 @@
* @param index The 0-based index, when more than one link with the same text is expected.
*/
public void assertLinkPresentWithExactText(String linkText, int index) {
- Assert.assertTrue("Link with Exact text [" + linkText + "] and index ["
+ assertTrue("Link with Exact text [" + linkText + "] and index ["
+ index + "] not found in response.", getTestingEngine()
.hasLinkWithExactText(linkText, index));
}
@@ -1974,7 +1974,7 @@
* @param index The 0-based index, when more than one link with the same text is expected.
*/
public void assertLinkNotPresentWithExactText(String linkText, int index) {
- Assert.assertTrue("Link with Exact text [" + linkText + "] and index "
+ assertTrue("Link with Exact text [" + linkText + "] and index "
+ index + " found in response.", !getTestingEngine()
.hasLinkWithExactText(linkText, index));
}
@@ -1988,7 +1988,7 @@
* you could just pass in <tt>"my_icon.png"</tt>.
*/
public void assertLinkPresentWithImage(String imageFileName) {
- Assert.assertTrue("Link with image file [" + imageFileName
+ assertTrue("Link with image file [" + imageFileName
+ "] not found in response.", getTestingEngine()
.hasLinkWithImage(imageFileName, 0));
}
@@ -2000,7 +2000,7 @@
* you could just pass in <tt>"my_icon.png"</tt>.
*/
public void assertLinkNotPresentWithImage(String imageFileName) {
- Assert.assertTrue("Link with image file [" + imageFileName
+ assertTrue("Link with image file [" + imageFileName
+ "] found in response.", !getTestingEngine().hasLinkWithImage(
imageFileName, 0));
}
@@ -2011,7 +2011,7 @@
* @param anID element id to test for.
*/
public void assertElementPresent(String anID) {
- Assert.assertTrue("Unable to locate element with id \"" + anID + "\"",
+ assertTrue("Unable to locate element with id \"" + anID + "\"",
getTestingEngine().hasElement(anID));
}
@@ -2021,7 +2021,7 @@
* @param anID element id to test for.
*/
public void assertElementNotPresent(String anID) {
- Assert.assertFalse("Located element with id \"" + anID + "\"",
+ assertFalse("Located element with id \"" + anID + "\"",
getTestingEngine().hasElement(anID));
}
@@ -2031,7 +2031,7 @@
* @param xpath element xpath to test for.
*/
public void assertElementPresentByXPath(String xpath) {
- Assert.assertTrue("Unable to locate element with xpath \"" + xpath
+ assertTrue("Unable to locate element with xpath \"" + xpath
+ "\"", getTestingEngine().hasElementByXPath(xpath));
}
@@ -2041,7 +2041,7 @@
* @param xpath element xpath to test for.
*/
public void assertElementNotPresentByXPath(String xpath) {
- Assert.assertFalse("Located element with xpath \"" + xpath + "\"",
+ assertFalse("Located element with xpath \"" + xpath + "\"",
getTestingEngine().hasElementByXPath(xpath));
}
@@ -2058,7 +2058,7 @@
* @param comment
*/
public void assertCommentPresent(String comment) {
- Assert.assertTrue("Comment present: '" + comment + "'", getComments().contains(comment.trim()));
+ assertTrue("Comment present: '" + comment + "'", getComments().contains(comment.trim()));
}
/**
@@ -2067,7 +2067,7 @@
* @param comment
*/
public void assertCommentNotPresent(String comment) {
- Assert.assertFalse("Comment not present: '" + comment + "'", getComments().contains(comment.trim()));
+ assertFalse("Comment not present: '" + comment + "'", getComments().contains(comment.trim()));
}
/**
@@ -2077,18 +2077,18 @@
* @param text to check for.
*/
public void assertTextInElement(String elementID, String text) {
- Assert.assertTrue("Unable to locate element with id \"" + elementID
+ assertTrue("Unable to locate element with id \"" + elementID
+ "\"", getTestingEngine().hasElement(elementID));
- Assert.assertTrue("Unable to locate [" + text + "] in element \""
+ assertTrue("Unable to locate [" + text + "] in element \""
+ elementID + "\"", getTestingEngine()
.isTextInElement(elementID, text));
}
public void assertTextNotInElement(String elementID, String text) {
assertElementPresent(elementID);
- Assert.assertTrue("Unable to locate element with id \"" + elementID
+ assertTrue("Unable to locate element with id \"" + elementID
+ "\"", getTestingEngine().hasElement(elementID));
- Assert.assertFalse("Text [" + text + "] found in element [" + elementID
+ assertFalse("Text [" + text + "] found in element [" + elementID
+ "] when not expected", getTestingEngine().isTextInElement(
elementID, text));
}
@@ -2100,9 +2100,9 @@
* @param regexp to match.
*/
public void assertMatchInElement(String elementID, String regexp) {
- Assert.assertTrue("Unable to locate element with id \"" + elementID
+ assertTrue("Unable to locate element with id \"" + elementID
+ "\"", getTestingEngine().hasElement(elementID));
- Assert.assertTrue("Unable to match [" + regexp + "] in element \""
+ assertTrue("Unable to match [" + regexp + "] in element \""
+ elementID + "\"", getTestingEngine().isMatchInElement(
elementID, regexp));
}
@@ -2115,9 +2115,9 @@
*/
public void assertNoMatchInElement(String elementID, String regexp) {
assertElementPresent(elementID);
- Assert.assertTrue("Unable to locate element with id \"" + elementID
+ assertTrue("Unable to locate element with id \"" + elementID
+ "\"", getTestingEngine().hasElement(elementID));
- Assert.assertFalse("Regexp [" + regexp + "] matched in element ["
+ assertFalse("Regexp [" + regexp + "] matched in element ["
+ elementID + "] when not expected", getTestingEngine()
.isMatchInElement(elementID, regexp));
}
@@ -2128,7 +2128,7 @@
* @param windowName
*/
public void assertWindowPresent(String windowName) {
- Assert.assertTrue("Unable to locate window [" + windowName + "].",
+ assertTrue("Unable to locate window [" + windowName + "].",
getTestingEngine().hasWindow(windowName));
}
@@ -2138,7 +2138,7 @@
* @param windowID Javascript window ID.
*/
public void assertWindowPresent(int windowID) {
- Assert.assertTrue("There is no window with index [" + windowID + "].",
+ assertTrue("There is no window with index [" + windowID + "].",
getTestingEngine().getWindowCount() > windowID);
}
@@ -2148,7 +2148,7 @@
* @param title
*/
public void assertWindowPresentWithTitle(String title) {
- Assert.assertTrue(
+ assertTrue(
"Unable to locate window with title [" + title + "].",
getTestingEngine().hasWindowByTitle(title));
}
@@ -2159,8 +2159,7 @@
* @param windowCount Window count
*/
public void assertWindowCountEquals(int windowCount) {
- Assert
- .assertTrue("Window count is "
+ assertTrue("Window count is "
+ getTestingEngine().getWindowCount() + " but "
+ windowCount + " was expected.", getTestingEngine()
.getWindowCount() == windowCount);
@@ -2172,7 +2171,7 @@
* @param frameNameOrId Name or ID of the frame. ID is checked first.
*/
public void assertFramePresent(String frameNameOrId) {
- Assert.assertTrue("Unable to locate frame with name or ID ["
+ assertTrue("Unable to locate frame with name or ID ["
+ frameNameOrId + "].", getTestingEngine().hasFrame(
frameNameOrId));
}
@@ -2189,7 +2188,7 @@
return;
}
}
- Assert.fail("Could not find Cookie with name [" + cookieName + "]");
+ fail("Could not find Cookie with name [" + cookieName + "]");
}
/**
@@ -2204,11 +2203,11 @@
for (Iterator<?> i = cookies.iterator(); i.hasNext();) {
Cookie c = (Cookie) i.next();
if (c.getName().equals(cookieName)) {
- Assert.assertEquals(expectedValue, c.getValue());
+ assertEquals(expectedValue, c.getValue());
return;
}
}
- Assert.fail("Should not be reached");
+ fail("Should not be reached");
}
/**
@@ -2223,19 +2222,19 @@
try {
re = new RE(regexp, RE.MATCH_SINGLELINE);
} catch (RESyntaxException e) {
- Assert.fail(e.toString());
+ fail(e.toString());
}
List<?> cookies = getTestingEngine().getCookies();
for (Iterator<?> i = cookies.iterator(); i.hasNext();) {
Cookie c = (Cookie) i.next();
if (c.getName().equals(cookieName)) {
- Assert.assertTrue("Unable to match [" + regexp
+ assertTrue("Unable to match [" + regexp
+ "] in cookie \"" + cookieName + "\"", re.match(c
.getValue()));
return;
}
}
- Assert.fail("Should not be reached");
+ fail("Should not be reached");
}
// Form interaction methods
@@ -2627,7 +2626,7 @@
*
* @param xpath XPath to search
* @return the requested element
- * @throws AssertionFailedError if the element xpath is not found
+ * @throws AssertionError if the element xpath is not found
*/
public IElement getElementByXPath(String xpath) {
assertElementPresentByXPath(xpath);
@@ -2640,7 +2639,7 @@
*
* @param id element ID to find
* @return the requested element
- * @throws AssertionFailedError if the element is not found
+ * @throws AssertionError if the element is not found
*/
public IElement getElementById(String id) {
assertElementPresent(id);
@@ -2662,7 +2661,7 @@
* Assert a label for a given ID exists.
*/
public void assertLabelPresent(String id) {
- Assert.assertNotNull("No label found with id [" + id + "]", getLabel(id));
+ assertNotNull("No label found with id [" + id + "]", getLabel(id));
}
/**
@@ -2705,7 +2704,7 @@
try {
re = new RE(regexp, RE.MATCH_SINGLELINE);
} catch (RESyntaxException e) {
- Assert.fail(e.toString());
+ fail(e.toString());
}
// get all labels
@@ -2713,7 +2712,7 @@
if (e.getName().equals("label") && re.match( e.getTextContent() ))
return; // label found
}
- Assert.fail("No label found with text matching [" + regexp + "]");
+ fail("No label found with text matching [" + regexp + "]");
}
/**
@@ -2755,7 +2754,7 @@
*/
private void assertLabeledFieldEquals(String identifier, IElement label, String fieldText) {
String value = getLabeledFieldValue(identifier, label);
- Assert.assertEquals("value of field for label [" + identifier + "] should be [" + fieldText + "]", fieldText, value == null ? "" : value);
+ assertEquals("value of field for label [" + identifier + "] should be [" + fieldText + "]", fieldText, value == null ? "" : value);
}
/**
@@ -2769,7 +2768,7 @@
public String getLabeledFieldValue(String identifier, IElement label) {
List<IElement> fields = getFieldsForLabel(label);
- Assert.assertFalse("No field found for label [" + identifier + "]", fields.isEmpty());
+ assertFalse("No field found for label [" + identifier + "]", fields.isEmpty());
String value = null;
// cycle through all fields trying to find value
for (IElement field : fields) {
@@ -2825,17 +2824,17 @@
*/
public void assertLabeledFieldEquals(String id, String fieldText) {
IElement label = getLabel(id);
- Assert.assertNotNull("no label for id [" + id + "] found", label);
+ assertNotNull("no label for id [" + id + "] found", label);
assertLabeledFieldEquals(id, label, fieldText);
}
public void setLabeledFormElementField(String id, String value) {
IElement label = getLabel(id);
- Assert.assertNotNull("no label for id [" + id + "] found", label);
+ assertNotNull("no label for id [" + id + "] found", label);
List<IElement> fields = getFieldsForLabel(label);
- Assert.assertNotSame("there should be at least one element referenced for label [" + id + "]", 0, fields.size());
+ assertNotSame("there should be at least one element referenced for label [" + id + "]", 0, fields.size());
// find the first element that we can change
for (IElement field : fields) {
@@ -2882,7 +2881,7 @@
}
}
- Assert.fail("could not find any fields for label [" + id + "] to set.");
+ fail("could not find any fields for label [" + id + "] to set.");
}
// Window and Frame Navigation Methods
@@ -2945,7 +2944,7 @@
try {
getTestingEngine().gotoPage(createUrl(url, getTestContext().getBaseUrl()));
} catch (MalformedURLException e) {
- Assert.fail(e.getLocalizedMessage());
+ fail(e.getLocalizedMessage());
}
}
@@ -3020,11 +3019,11 @@
File tmp = File.createTempFile("jwebunit", null);
tmp.deleteOnExit();
saveAs(tmp);
- Assert.assertTrue("Files are not binary equals.", areFilesEqual(
+ assertTrue("Files are not binary equals.", areFilesEqual(
expected, tmp.toURI().toURL()));
} catch (IOException e) {
e.printStackTrace();
- Assert.fail(e.toString());
+ fail(e.toString());
}
}
@@ -3126,7 +3125,7 @@
try {
re = new RE(regexp, RE.MATCH_SINGLELINE);
} catch (RESyntaxException e) {
- Assert.fail(e.toString());
+ fail(e.toString());
}
return re;
}
@@ -3220,10 +3219,10 @@
private void assertArraysEqual(String[] exptected, String[] returned) {
- Assert.assertEquals("Arrays not same length", exptected.length,
+ assertEquals("Arrays not same length", exptected.length,
returned.length);
for (int i = 0; i < returned.length; i++) {
- Assert.assertEquals("Elements " + i + "not equal", exptected[i],
+ assertEquals("Elements " + i + "not equal", exptected[i],
returned[i]);
}
}
@@ -3251,7 +3250,7 @@
getTestingEngine().setExpectedJavaScriptAlert(
new JavascriptAlert[] { new JavascriptAlert(message) });
} catch (ExpectedJavascriptAlertException e) {
- Assert.fail("You previously tell that alert with message ["
+ fail("You previously tell that alert with message ["
+ e.getAlertMessage()
+ "] was expected, but nothing appeared.");
}
@@ -3270,7 +3269,7 @@
try {
getTestingEngine().setExpectedJavaScriptAlert(alerts);
} catch (ExpectedJavascriptAlertException e) {
- Assert.fail("You previously tell that alert with message ["
+ fail("You previously tell that alert with message ["
+ e.getAlertMessage()
+ "] was expected, but nothing appeared.");
}
@@ -3288,7 +3287,7 @@
new JavascriptConfirm[] { new JavascriptConfirm(message,
action) });
} catch (ExpectedJavascriptConfirmException e) {
- Assert.fail("You previously tell that confirm with message ["
+ fail("You previously tell that confirm with message ["
+ e.getConfirmMessage()
+ "] was expected, but nothing appeared.");
}
@@ -3302,7 +3301,7 @@
*/
public void setExpectedJavaScriptConfirm(String[] messages,
boolean[] actions) {
- Assert.assertEquals(
+ assertEquals(
"You should give the same number of messages and actions",
messages.length, actions.length);
JavascriptConfirm[] confirms = new JavascriptConfirm[messages.length];
@@ -3312,7 +3311,7 @@
try {
getTestingEngine().setExpectedJavaScriptConfirm(confirms);
} catch (ExpectedJavascriptConfirmException e) {
- Assert.fail("You previously tell that confirm with message ["
+ fail("You previously tell that confirm with message ["
+ e.getConfirmMessage()
+ "] was expected, but nothing appeared.");
}
@@ -3330,7 +3329,7 @@
new JavascriptPrompt[] { new JavascriptPrompt(message,
input) });
} catch (ExpectedJavascriptPromptException e) {
- Assert.fail("You previously tell that prompt with message ["
+ fail("You previously tell that prompt with message ["
+ e.getPromptMessage()
+ "] was expected, but nothing appeared.");
}
@@ -3343,7 +3342,7 @@
* @param inputs What we should put in the prompt (null if user press Cancel)
*/
public void setExpectedJavaScriptPrompt(String[] messages, String[] inputs) {
- Assert.assertEquals(
+ assertEquals(
"You should give the same number of messages and inputs",
messages.length, inputs.length);
JavascriptPrompt[] prompts = new JavascriptPrompt[messages.length];
@@ -3353,7 +3352,7 @@
try {
getTestingEngine().setExpectedJavaScriptPrompt(prompts);
} catch (ExpectedJavascriptPromptException e) {
- Assert.fail("You previ...
[truncated message content] |
|
From: <he...@us...> - 2010-10-18 09:11:37
|
Revision: 854
http://jwebunit.svn.sourceforge.net/jwebunit/?rev=854&view=rev
Author: henryju
Date: 2010-10-18 09:11:31 +0000 (Mon, 18 Oct 2010)
Log Message:
-----------
Updated some plugins to latest version.
Modified Paths:
--------------
trunk/pom.xml
Modified: trunk/pom.xml
===================================================================
--- trunk/pom.xml 2010-10-18 09:08:30 UTC (rev 853)
+++ trunk/pom.xml 2010-10-18 09:11:31 UTC (rev 854)
@@ -221,7 +221,7 @@
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-assembly-plugin</artifactId>
- <version>2.2-beta-5</version>
+ <version>2.2</version>
<configuration>
<attach>false</attach>
<descriptors>
@@ -234,7 +234,7 @@
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-release-plugin</artifactId>
- <version>2.0</version>
+ <version>2.1</version>
<configuration>
<autoVersionSubmodules>true</autoVersionSubmodules>
<preparationGoals>clean install</preparationGoals>
@@ -291,7 +291,7 @@
<plugin>
<groupId>com.mycila.maven-license-plugin</groupId>
<artifactId>maven-license-plugin</artifactId>
- <version>1.6.1</version>
+ <version>1.8.0</version>
<configuration>
<header>${topDirectoryLocation}/src/license/header.txt</header>
<aggregate>false</aggregate>
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <he...@us...> - 2010-10-18 09:08:37
|
Revision: 853
http://jwebunit.svn.sourceforge.net/jwebunit/?rev=853&view=rev
Author: henryju
Date: 2010-10-18 09:08:30 +0000 (Mon, 18 Oct 2010)
Log Message:
-----------
Updated to surefire 2.6 to support parallel build.
Modified Paths:
--------------
trunk/jwebunit-htmlunit-plugin/pom.xml
trunk/jwebunit-selenium-plugin/pom.xml
Modified: trunk/jwebunit-htmlunit-plugin/pom.xml
===================================================================
--- trunk/jwebunit-htmlunit-plugin/pom.xml 2010-10-18 07:41:54 UTC (rev 852)
+++ trunk/jwebunit-htmlunit-plugin/pom.xml 2010-10-18 09:08:30 UTC (rev 853)
@@ -14,7 +14,6 @@
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-surefire-plugin</artifactId>
- <version>2.5</version>
<configuration>
<includes>
<include>**/*Test.java</include>
Modified: trunk/jwebunit-selenium-plugin/pom.xml
===================================================================
--- trunk/jwebunit-selenium-plugin/pom.xml 2010-10-18 07:41:54 UTC (rev 852)
+++ trunk/jwebunit-selenium-plugin/pom.xml 2010-10-18 09:08:30 UTC (rev 853)
@@ -14,7 +14,6 @@
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-surefire-plugin</artifactId>
- <version>2.5</version>
<configuration>
<testFailureIgnore>true</testFailureIgnore>
<skip>true</skip>
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <he...@us...> - 2010-10-18 07:42:00
|
Revision: 852
http://jwebunit.svn.sourceforge.net/jwebunit/?rev=852&view=rev
Author: henryju
Date: 2010-10-18 07:41:54 +0000 (Mon, 18 Oct 2010)
Log Message:
-----------
Prevents deployment of tests.
Modified Paths:
--------------
trunk/jwebunit-commons-tests/pom.xml
Modified: trunk/jwebunit-commons-tests/pom.xml
===================================================================
--- trunk/jwebunit-commons-tests/pom.xml 2010-10-05 14:40:30 UTC (rev 851)
+++ trunk/jwebunit-commons-tests/pom.xml 2010-10-18 07:41:54 UTC (rev 852)
@@ -38,5 +38,7 @@
</dependencies>
<properties>
<topDirectoryLocation>..</topDirectoryLocation>
+ <!-- Prevents deployment as this module is not intended to be used by end-users -->
+ <maven.deploy.skip>true</maven.deploy.skip>
</properties>
</project>
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <he...@us...> - 2010-10-05 14:40:36
|
Revision: 851
http://jwebunit.svn.sourceforge.net/jwebunit/?rev=851&view=rev
Author: henryju
Date: 2010-10-05 14:40:30 +0000 (Tue, 05 Oct 2010)
Log Message:
-----------
Updated change report (deprecated plugin property and added XSD + validation).
Modified Paths:
--------------
trunk/pom.xml
trunk/src/changes/changes.xml
Modified: trunk/pom.xml
===================================================================
--- trunk/pom.xml 2010-10-05 14:29:31 UTC (rev 850)
+++ trunk/pom.xml 2010-10-05 14:40:30 UTC (rev 851)
@@ -317,6 +317,23 @@
</execution>
</executions>
</plugin>
+ <plugin>
+ <groupId>org.apache.maven.plugins</groupId>
+ <artifactId>maven-changes-plugin</artifactId>
+ <version>2.3</version>
+ <executions>
+ <execution>
+ <id>validate-changes</id>
+ <phase>pre-site</phase>
+ <goals>
+ <goal>changes-validate</goal>
+ </goals>
+ <configuration>
+ <failOnError>true</failOnError>
+ </configuration>
+ </execution>
+ </executions>
+ </plugin>
</plugins>
</build>
<properties>
@@ -494,8 +511,9 @@
</reportSet>
</reportSets>
<configuration>
- <issueLinkTemplate>
- http://sourceforge.net/support/tracker.php?aid=%ISSUE% </issueLinkTemplate>
+ <issueLinkTemplatePerSystem>
+ <sourceforge>http://sourceforge.net/support/tracker.php?aid=%ISSUE%</sourceforge>
+ </issueLinkTemplatePerSystem>
</configuration>
</plugin>
<plugin>
Modified: trunk/src/changes/changes.xml
===================================================================
--- trunk/src/changes/changes.xml 2010-10-05 14:29:31 UTC (rev 850)
+++ trunk/src/changes/changes.xml 2010-10-05 14:40:30 UTC (rev 851)
@@ -20,7 +20,10 @@
-->
-<document>
+<document xmlns="http://maven.apache.org/changes/1.0.0"
+ xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xsi:schemaLocation="http://maven.apache.org/changes/1.0.0 http://maven.apache.org/xsd/changes-1.0.0.xsd">
+
<properties>
<title>JWebUnit changes</title>
<author email="henryju at users.sourceforge.net">
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <he...@us...> - 2010-10-05 14:29:37
|
Revision: 850
http://jwebunit.svn.sourceforge.net/jwebunit/?rev=850&view=rev
Author: henryju
Date: 2010-10-05 14:29:31 +0000 (Tue, 05 Oct 2010)
Log Message:
-----------
Updated Maven configuration (especially site & reporting) to works with Maven 3.
Modified Paths:
--------------
trunk/pom.xml
Modified: trunk/pom.xml
===================================================================
--- trunk/pom.xml 2010-10-05 11:59:59 UTC (rev 849)
+++ trunk/pom.xml 2010-10-05 14:29:31 UTC (rev 850)
@@ -1,4 +1,5 @@
-<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
+<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
<modelVersion>4.0.0</modelVersion>
<groupId>net.sourceforge.jwebunit</groupId>
<artifactId>jwebunit</artifactId>
@@ -60,8 +61,8 @@
<name>Julien Henry</name>
<email>henryju at users.sourceforge.net</email>
<url />
- <organization>Capgemini</organization>
- <organizationUrl>http://www.capgemini.com</organizationUrl>
+ <organization>SERLI</organization>
+ <organizationUrl>http://www.serli.com</organizationUrl>
<roles>
<role>Developer</role>
</roles>
@@ -198,49 +199,49 @@
<build>
<pluginManagement>
<plugins>
- <plugin>
- <groupId>org.apache.maven.plugins</groupId>
- <artifactId>maven-compiler-plugin</artifactId>
- <version>2.3.2</version>
- <configuration>
- <source>1.5</source>
- <target>1.5</target>
- </configuration>
- </plugin>
- <plugin>
- <groupId>org.apache.maven.plugins</groupId>
- <artifactId>maven-surefire-plugin</artifactId>
- <version>2.6</version>
- </plugin>
- <plugin>
- <groupId>org.apache.maven.plugins</groupId>
- <artifactId>maven-resources-plugin</artifactId>
- <version>2.4.3</version>
- </plugin>
- <plugin>
- <groupId>org.apache.maven.plugins</groupId>
- <artifactId>maven-assembly-plugin</artifactId>
- <version>2.2-beta-5</version>
- <configuration>
- <attach>false</attach>
- <descriptors>
- <descriptor>
- src/assemble/release.xml
+ <plugin>
+ <groupId>org.apache.maven.plugins</groupId>
+ <artifactId>maven-compiler-plugin</artifactId>
+ <version>2.3.2</version>
+ <configuration>
+ <source>1.5</source>
+ <target>1.5</target>
+ </configuration>
+ </plugin>
+ <plugin>
+ <groupId>org.apache.maven.plugins</groupId>
+ <artifactId>maven-surefire-plugin</artifactId>
+ <version>2.6</version>
+ </plugin>
+ <plugin>
+ <groupId>org.apache.maven.plugins</groupId>
+ <artifactId>maven-resources-plugin</artifactId>
+ <version>2.4.3</version>
+ </plugin>
+ <plugin>
+ <groupId>org.apache.maven.plugins</groupId>
+ <artifactId>maven-assembly-plugin</artifactId>
+ <version>2.2-beta-5</version>
+ <configuration>
+ <attach>false</attach>
+ <descriptors>
+ <descriptor>
+ src/assemble/release.xml
</descriptor>
- </descriptors>
- </configuration>
- </plugin>
- <plugin>
- <groupId>org.apache.maven.plugins</groupId>
- <artifactId>maven-release-plugin</artifactId>
- <version>2.0</version>
- <configuration>
- <autoVersionSubmodules>true</autoVersionSubmodules>
- <preparationGoals>clean install</preparationGoals>
- <mavenExecutorId>forked-path</mavenExecutorId>
- </configuration>
- </plugin>
+ </descriptors>
+ </configuration>
+ </plugin>
<plugin>
+ <groupId>org.apache.maven.plugins</groupId>
+ <artifactId>maven-release-plugin</artifactId>
+ <version>2.0</version>
+ <configuration>
+ <autoVersionSubmodules>true</autoVersionSubmodules>
+ <preparationGoals>clean install</preparationGoals>
+ <mavenExecutorId>forked-path</mavenExecutorId>
+ </configuration>
+ </plugin>
+ <plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>javacc-maven-plugin</artifactId>
<version>2.6</version>
@@ -253,8 +254,16 @@
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-site-plugin</artifactId>
- <version>2.1</version>
+ <version>2.1.1</version>
</plugin>
+ <plugin>
+ <groupId>org.apache.maven.plugins</groupId>
+ <artifactId>maven-javadoc-plugin</artifactId>
+ <version>2.7</version>
+ <configuration>
+ <quiet>true</quiet>
+ </configuration>
+ </plugin>
</plugins>
</pluginManagement>
<plugins>
@@ -296,8 +305,8 @@
<exclude>src/main/javacc/Java1.5.jj</exclude>
<exclude>src/main/javacc/Token.java</exclude>
<exclude>src/main/resources/testcases/CharsetTest/charset.html_utf-8</exclude>
- <exclude>src/main/resources/testcases/NonHtmlContentTest/text.bin</exclude>
- <exclude>src/main/resources/testcases/FramesAndWindowsTest/TopFrame.html</exclude>
+ <exclude>src/main/resources/testcases/NonHtmlContentTest/text.bin</exclude>
+ <exclude>src/main/resources/testcases/FramesAndWindowsTest/TopFrame.html</exclude>
</excludes>
</configuration>
<executions>
@@ -407,13 +416,46 @@
</plugins>
</build>
</profile>
+ <profile>
+ <id>maven-3</id>
+ <activation>
+ <file>
+ <!-- This employs that the basedir expression is only recognized by Maven 3.x (see MNG-2363) -->
+ <exists>${basedir}</exists>
+ </file>
+ </activation>
+ <build>
+ <pluginManagement>
+ <plugins>
+ <plugin>
+ <groupId>org.apache.maven.plugins</groupId>
+ <artifactId>maven-site-plugin</artifactId>
+ <version>3.0-beta-2</version>
+ </plugin>
+ </plugins>
+ </pluginManagement>
+ <plugins>
+ <plugin>
+ <artifactId>maven-site-plugin</artifactId>
+ <executions>
+ <execution>
+ <id>attach-descriptor</id>
+ <goals>
+ <goal>attach-descriptor</goal>
+ </goals>
+ </execution>
+ </executions>
+ </plugin>
+ </plugins>
+ </build>
+ </profile>
</profiles>
<reporting>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-checkstyle-plugin</artifactId>
- <version>2.5</version>
+ <version>2.6</version>
<configuration>
<configLocation>
${basedir}/${topDirectoryLocation}/src/checkstyle/jwebunit-checkstyle.xml
@@ -421,13 +463,18 @@
<headerLocation>
${basedir}/${topDirectoryLocation}/src/checkstyle/header-checkstyle.txt
</headerLocation>
- <xrefLocation>xref</xrefLocation>
+ <xrefLocation>
+ ${project.reporting.outputDirectory}/${topDirectoryLocation}/xref
+ </xrefLocation>
</configuration>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-surefire-report-plugin</artifactId>
- <version>2.4.3</version>
+ <version>2.6</version>
+ <configuration>
+ <aggregate>true</aggregate>
+ </configuration>
</plugin>
<plugin>
<groupId>org.codehaus.mojo</groupId>
@@ -437,7 +484,7 @@
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-changes-plugin</artifactId>
- <version>2.2</version>
+ <version>2.3</version>
<inherited>false</inherited>
<reportSets>
<reportSet>
@@ -448,59 +495,48 @@
</reportSets>
<configuration>
<issueLinkTemplate>
- http://sourceforge.net/support/tracker.php?aid=%ISSUE%
- </issueLinkTemplate>
+ http://sourceforge.net/support/tracker.php?aid=%ISSUE% </issueLinkTemplate>
</configuration>
</plugin>
<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>findbugs-maven-plugin</artifactId>
<version>2.3.1</version>
+ <configuration>
+ <xrefLocation>
+ ${project.reporting.outputDirectory}/${topDirectoryLocation}/xref
+ </xrefLocation>
+ </configuration>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-javadoc-plugin</artifactId>
- <version>2.6.1</version>
+ <version>2.7</version>
<reportSets>
<reportSet>
<id>aggregate</id>
<configuration>
- <excludePackageNames>
- net.sourceforge.jwebunit.javacc:net.sourceforge.jwebunit.tests
- </excludePackageNames>
- <links>
- <link>
- http://java.sun.com/j2se/1.5.0/docs/api/
- </link>
- <link>
- http://hc.apache.org/httpclient-3.x/apidocs/
- </link>
- <link>http://junit.sourceforge.net/junit3.8.1/javadoc/</link>
- <link>
- http://htmlunit.sourceforge.net/apidocs/
- </link>
- <link>http://release.seleniumhq.org/selenium-remote-control/0.9.2/doc/java/</link>
- </links>
- <groups>
- <group>
- <title>Core Packages</title>
- <packages>
- net.sourceforge.jwebunit.api*:net.sourceforge.jwebunit.junit*:net.sourceforge.jwebunit.exception*:net.sourceforge.jwebunit.html*:net.sourceforge.jwebunit.javascript*:net.sourceforge.jwebunit.util*
- </packages>
- </group>
- <group>
- <title>HtmlUnit Packages</title>
- <packages>
- net.sourceforge.jwebunit.htmlunit*
- </packages>
- </group>
- <group>
- <title>Selenium Packages</title>
- <packages>
- net.sourceforge.jwebunit.selenium*
- </packages>
- </group>
- </groups>
+ <excludePackageNames>net.sourceforge.jwebunit.javacc:net.sourceforge.jwebunit.tests</excludePackageNames>
+ <links>
+ <link>http://download.oracle.com/javase/1.5.0/docs/api/</link>
+ <link>http://hc.apache.org/httpcomponents-client-ga/httpclient/apidocs/</link>
+ <link>http://kentbeck.github.com/junit/javadoc/latest/</link>
+ <link>http://htmlunit.sourceforge.net/apidocs/</link>
+ </links>
+ <groups>
+ <group>
+ <title>Core Packages</title>
+ <packages>net.sourceforge.jwebunit.api*:net.sourceforge.jwebunit.junit*:net.sourceforge.jwebunit.exception*:net.sourceforge.jwebunit.html*:net.sourceforge.jwebunit.javascript*:net.sourceforge.jwebunit.util*</packages>
+ </group>
+ <group>
+ <title>HtmlUnit Packages</title>
+ <packages>net.sourceforge.jwebunit.htmlunit*</packages>
+ </group>
+ <group>
+ <title>Selenium Packages</title>
+ <packages>net.sourceforge.jwebunit.selenium*</packages>
+ </group>
+ </groups>
</configuration>
<reports>
<report>aggregate</report>
@@ -511,7 +547,7 @@
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-jxr-plugin</artifactId>
- <version>2.1</version>
+ <version>2.2</version>
<configuration>
<aggregate>true</aggregate>
</configuration>
@@ -520,15 +556,16 @@
<groupId>org.codehaus.mojo</groupId>
<artifactId>taglist-maven-plugin</artifactId>
<version>2.4</version>
+ <configuration>
+ <aggregate>true</aggregate>
+ </configuration>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-pmd-plugin</artifactId>
- <version>2.4</version>
+ <version>2.5</version>
<configuration>
- <xrefLocation>
- ${project.reporting.outputDirectory}/${topDirectoryLocation}/xref
- </xrefLocation>
+ <aggregate>true</aggregate>
<targetJdk>1.5</targetJdk>
</configuration>
</plugin>
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <he...@us...> - 2010-10-05 12:00:07
|
Revision: 849
http://jwebunit.svn.sourceforge.net/jwebunit/?rev=849&view=rev
Author: henryju
Date: 2010-10-05 11:59:59 +0000 (Tue, 05 Oct 2010)
Log Message:
-----------
Updated Maven plugins & pom configuration.
Modified Paths:
--------------
trunk/pom.xml
Modified: trunk/pom.xml
===================================================================
--- trunk/pom.xml 2010-10-05 11:48:08 UTC (rev 848)
+++ trunk/pom.xml 2010-10-05 11:59:59 UTC (rev 849)
@@ -1,256 +1,285 @@
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
- <modelVersion>4.0.0</modelVersion>
- <groupId>net.sourceforge.jwebunit</groupId>
- <artifactId>jwebunit</artifactId>
- <name>JWebUnit</name>
- <version>2.5-SNAPSHOT</version>
- <packaging>pom</packaging>
- <description>
- JWebUnit is a Java framework that facilitates creation of
- acceptance tests for web applications. It evolved from a project
- where we were using HttpUnit and JUnit to create acceptance
- tests. As the tests were being written, they were continuously
- refactored to remove duplication and other bad smells in the
- test code. JWebUnit is the result of these refactorings.
- </description>
- <url>http://jwebunit.sourceforge.net</url>
- <issueManagement>
- <system>sourceforge</system>
- <url>http://sourceforge.net/tracker/?group_id=61302</url>
- </issueManagement>
- <inceptionYear>2002</inceptionYear>
- <modules>
- <module>jwebunit-webtestcase-generator</module>
- <module>jwebunit-core</module>
- <module>jwebunit-commons-tests</module>
- <module>jwebunit-htmlunit-plugin</module>
- <module>jwebunit-selenium-plugin</module>
- </modules>
- <mailingLists>
- <mailingList>
- <name>JWebUnit Development Mailing list</name>
- <subscribe>
- http://lists.sourceforge.net/lists/listinfo/jwebunit-development
- </subscribe>
- <unsubscribe>
- http://lists.sourceforge.net/lists/listinfo/jwebunit-development
- </unsubscribe>
- <archive>
- http://sourceforge.net/mailarchive/forum.php?forum_name=jwebunit-development
- </archive>
- <post>jwe...@li...</post>
- </mailingList>
- <mailingList>
- <name>JWebUnit User Mailing list</name>
- <subscribe>
- http://lists.sourceforge.net/lists/listinfo/jwebunit-users
- </subscribe>
- <unsubscribe>
- http://lists.sourceforge.net/lists/listinfo/jwebunit-users
- </unsubscribe>
- <archive>
- http://sourceforge.net/mailarchive/forum.php?forum_name=jwebunit-users
- </archive>
- <post>jwe...@li...</post>
- </mailingList>
- </mailingLists>
- <developers>
- <developer>
- <id>henryju</id>
- <name>Julien Henry</name>
- <email>henryju at users.sourceforge.net</email>
- <url />
- <organization>Capgemini</organization>
- <organizationUrl>http://www.capgemini.com</organizationUrl>
- <roles>
- <role>Developer</role>
- </roles>
- <timezone>+2</timezone>
- </developer>
- <developer>
- <id>joshlane</id>
- <name>Josh Lane</name>
- <email>joshlane at users.sourceforge.net</email>
- <url />
- <organization>Brontes Technologies</organization>
- <organizationUrl>
- http://solutions.3m.com/wps/portal/3M/en_US/LavaCOS/3MESPE-LavaCOS/
- </organizationUrl>
- <roles>
- <role>Developer</role>
- </roles>
- <timezone>-5</timezone>
- </developer>
- <developer>
- <id>jevonwright</id>
- <name>Jevon Wright</name>
- <email>jevonwright at users.sourceforge.net</email>
- <url>http://www.jevon.org</url>
- <organization />
- <organizationUrl />
- <roles>
- <role>Developer</role>
- </roles>
- <timezone>+13</timezone>
- </developer>
- </developers>
- <contributors>
- <contributor>
- <name>Jim Weaver</name>
- <email>jimweaver at users.sourceforge.net</email>
- <organization>Thoughtworks</organization>
- <roles>
- <role>All-Hands person</role>
- </roles>
- <timezone>-5</timezone>
- </contributor>
- <contributor>
- <name>Wilkes Joiner</name>
- <email>wilkesj at users.sourceforge.net</email>
- <organization />
- <roles>
- <role>All-Hands person</role>
- </roles>
- </contributor>
- <contributor>
- <name>Vivek Venugopalan</name>
- <email>vivek at magic hypen cauldron dot com</email>
- <url>http://www.magic-cauldron.com</url>
- <organization />
- <roles>
- <role>All-Hands person</role>
- </roles>
- <timezone>+5.5</timezone>
- </contributor>
- <contributor>
- <name>Martijn Dashorst</name>
- <email>dashorst at users.sourceforge.net</email>
- <url>http://www.dashorst.dds.nl</url>
- <organization>Topicus B.V.</organization>
- <roles>
- <role>All-Hands person</role>
- </roles>
- <timezone>+1</timezone>
- </contributor>
- <contributor>
- <name>Nicholas Neuberger</name>
- <email>nneuberger at users.sourceforge.net</email>
- <url />
- <organization>Sunshine Solar</organization>
- <roles>
- <role>Developer</role>
- </roles>
- <timezone>-6</timezone>
- </contributor>
- <contributor>
- <name>Jon Frisby</name>
- <email>jf...@ma...</email>
- <url />
- <organization />
- <organizationUrl />
- <roles />
- <timezone />
- <properties />
- </contributor>
- <contributor>
- <name>Fred Burlet</name>
- <email>fb...@ki...</email>
- <url />
- <organization />
- <organizationUrl />
- <roles />
- <timezone />
- <properties />
- </contributor>
- <contributor>
- <name>Mike C</name>
- <email>mtc3bmtc3b at users.sourceforge.net</email>
- <url />
- <organization />
- <organizationUrl />
- <roles />
- <timezone />
- <properties />
- </contributor>
- </contributors>
- <licenses>
- <license>
- <name>LGPL License</name>
- <url>${topDirectoryLocation}/LICENSE.txt</url>
- </license>
- </licenses>
- <scm>
- <connection>scm:svn:http://jwebunit.svn.sourceforge.net/svnroot/jwebunit/trunk</connection>
- <developerConnection>scm:svn:https://jwebunit.svn.sourceforge.net/svnroot/jwebunit/trunk</developerConnection>
- <url>http://jwebunit.svn.sourceforge.net/viewvc/jwebunit/trunk</url>
- </scm>
- <organization>
- <name>SourceForge</name>
- <url>http://sourceforge.net</url>
- </organization>
- <repositories>
- <repository>
- <id>selenium</id>
- <name>Selenium release repository</name>
- <url>http://nexus.openqa.org/content/repositories/releases</url>
- </repository>
- </repositories>
- <build>
- <plugins>
- <plugin>
- <groupId>org.apache.maven.plugins</groupId>
- <artifactId>maven-assembly-plugin</artifactId>
- <version>2.2-beta-5</version>
- <configuration>
- <attach>false</attach>
- <descriptors>
- <descriptor>
- src/assemble/release.xml
- </descriptor>
- </descriptors>
- </configuration>
- </plugin>
- <plugin>
- <groupId>org.apache.maven.plugins</groupId>
- <artifactId>maven-release-plugin</artifactId>
- <version>2.0</version>
- <configuration>
- <autoVersionSubmodules>true</autoVersionSubmodules>
- <preparationGoals>clean install</preparationGoals>
- <mavenExecutorId>forked-path</mavenExecutorId>
- </configuration>
- </plugin>
- <plugin>
- <groupId>org.apache.maven.plugins</groupId>
- <artifactId>maven-compiler-plugin</artifactId>
- <version>2.3.2</version>
- <configuration>
- <source>1.5</source>
- <target>1.5</target>
- </configuration>
- </plugin>
- <plugin>
- <groupId>org.apache.maven.plugins</groupId>
- <artifactId>maven-toolchains-plugin</artifactId>
- <version>1.0</version>
- <executions>
- <execution>
- <phase>validate</phase>
- <goals>
- <goal>toolchain</goal>
- </goals>
- </execution>
- </executions>
- <configuration>
- <toolchains>
- <jdk>
- <version>1.5</version>
- <vendor>sun</vendor>
- </jdk>
- </toolchains>
- </configuration>
- </plugin>
+ <modelVersion>4.0.0</modelVersion>
+ <groupId>net.sourceforge.jwebunit</groupId>
+ <artifactId>jwebunit</artifactId>
+ <name>JWebUnit</name>
+ <version>2.5-SNAPSHOT</version>
+ <packaging>pom</packaging>
+ <description>
+ JWebUnit is a Java framework that facilitates creation of
+ acceptance tests for web applications. It evolved from a project
+ where we were using HttpUnit and JUnit to create acceptance
+ tests. As the tests were being written, they were continuously
+ refactored to remove duplication and other bad smells in the
+ test code. JWebUnit is the result of these refactorings.
+ </description>
+ <url>http://jwebunit.sourceforge.net</url>
+ <issueManagement>
+ <system>sourceforge</system>
+ <url>http://sourceforge.net/tracker/?group_id=61302</url>
+ </issueManagement>
+ <inceptionYear>2002</inceptionYear>
+ <modules>
+ <module>jwebunit-webtestcase-generator</module>
+ <module>jwebunit-core</module>
+ <module>jwebunit-commons-tests</module>
+ <module>jwebunit-htmlunit-plugin</module>
+ <module>jwebunit-selenium-plugin</module>
+ </modules>
+ <mailingLists>
+ <mailingList>
+ <name>JWebUnit Development Mailing list</name>
+ <subscribe>
+ http://lists.sourceforge.net/lists/listinfo/jwebunit-development
+ </subscribe>
+ <unsubscribe>
+ http://lists.sourceforge.net/lists/listinfo/jwebunit-development
+ </unsubscribe>
+ <archive>
+ http://sourceforge.net/mailarchive/forum.php?forum_name=jwebunit-development
+ </archive>
+ <post>jwe...@li...</post>
+ </mailingList>
+ <mailingList>
+ <name>JWebUnit User Mailing list</name>
+ <subscribe>
+ http://lists.sourceforge.net/lists/listinfo/jwebunit-users
+ </subscribe>
+ <unsubscribe>
+ http://lists.sourceforge.net/lists/listinfo/jwebunit-users
+ </unsubscribe>
+ <archive>
+ http://sourceforge.net/mailarchive/forum.php?forum_name=jwebunit-users
+ </archive>
+ <post>jwe...@li...</post>
+ </mailingList>
+ </mailingLists>
+ <developers>
+ <developer>
+ <id>henryju</id>
+ <name>Julien Henry</name>
+ <email>henryju at users.sourceforge.net</email>
+ <url />
+ <organization>Capgemini</organization>
+ <organizationUrl>http://www.capgemini.com</organizationUrl>
+ <roles>
+ <role>Developer</role>
+ </roles>
+ <timezone>+2</timezone>
+ </developer>
+ <developer>
+ <id>joshlane</id>
+ <name>Josh Lane</name>
+ <email>joshlane at users.sourceforge.net</email>
+ <url />
+ <organization>Brontes Technologies</organization>
+ <organizationUrl>
+ http://solutions.3m.com/wps/portal/3M/en_US/LavaCOS/3MESPE-LavaCOS/
+ </organizationUrl>
+ <roles>
+ <role>Developer</role>
+ </roles>
+ <timezone>-5</timezone>
+ </developer>
+ <developer>
+ <id>jevonwright</id>
+ <name>Jevon Wright</name>
+ <email>jevonwright at users.sourceforge.net</email>
+ <url>http://www.jevon.org</url>
+ <organization />
+ <organizationUrl />
+ <roles>
+ <role>Developer</role>
+ </roles>
+ <timezone>+13</timezone>
+ </developer>
+ </developers>
+ <contributors>
+ <contributor>
+ <name>Jim Weaver</name>
+ <email>jimweaver at users.sourceforge.net</email>
+ <organization>Thoughtworks</organization>
+ <roles>
+ <role>All-Hands person</role>
+ </roles>
+ <timezone>-5</timezone>
+ </contributor>
+ <contributor>
+ <name>Wilkes Joiner</name>
+ <email>wilkesj at users.sourceforge.net</email>
+ <organization />
+ <roles>
+ <role>All-Hands person</role>
+ </roles>
+ </contributor>
+ <contributor>
+ <name>Vivek Venugopalan</name>
+ <email>vivek at magic hypen cauldron dot com</email>
+ <url>http://www.magic-cauldron.com</url>
+ <organization />
+ <roles>
+ <role>All-Hands person</role>
+ </roles>
+ <timezone>+5.5</timezone>
+ </contributor>
+ <contributor>
+ <name>Martijn Dashorst</name>
+ <email>dashorst at users.sourceforge.net</email>
+ <url>http://www.dashorst.dds.nl</url>
+ <organization>Topicus B.V.</organization>
+ <roles>
+ <role>All-Hands person</role>
+ </roles>
+ <timezone>+1</timezone>
+ </contributor>
+ <contributor>
+ <name>Nicholas Neuberger</name>
+ <email>nneuberger at users.sourceforge.net</email>
+ <url />
+ <organization>Sunshine Solar</organization>
+ <roles>
+ <role>Developer</role>
+ </roles>
+ <timezone>-6</timezone>
+ </contributor>
+ <contributor>
+ <name>Jon Frisby</name>
+ <email>jf...@ma...</email>
+ <url />
+ <organization />
+ <organizationUrl />
+ <roles />
+ <timezone />
+ <properties />
+ </contributor>
+ <contributor>
+ <name>Fred Burlet</name>
+ <email>fb...@ki...</email>
+ <url />
+ <organization />
+ <organizationUrl />
+ <roles />
+ <timezone />
+ <properties />
+ </contributor>
+ <contributor>
+ <name>Mike C</name>
+ <email>mtc3bmtc3b at users.sourceforge.net</email>
+ <url />
+ <organization />
+ <organizationUrl />
+ <roles />
+ <timezone />
+ <properties />
+ </contributor>
+ </contributors>
+ <licenses>
+ <license>
+ <name>LGPL License</name>
+ <url>${topDirectoryLocation}/LICENSE.txt</url>
+ </license>
+ </licenses>
+ <scm>
+ <connection>scm:svn:http://jwebunit.svn.sourceforge.net/svnroot/jwebunit/trunk</connection>
+ <developerConnection>scm:svn:https://jwebunit.svn.sourceforge.net/svnroot/jwebunit/trunk</developerConnection>
+ <url>http://jwebunit.svn.sourceforge.net/viewvc/jwebunit/trunk</url>
+ </scm>
+ <organization>
+ <name>SourceForge</name>
+ <url>http://sourceforge.net</url>
+ </organization>
+ <repositories>
+ <repository>
+ <id>selenium</id>
+ <name>Selenium release repository</name>
+ <url>http://nexus.openqa.org/content/repositories/releases</url>
+ </repository>
+ </repositories>
+ <build>
+ <pluginManagement>
+ <plugins>
+ <plugin>
+ <groupId>org.apache.maven.plugins</groupId>
+ <artifactId>maven-compiler-plugin</artifactId>
+ <version>2.3.2</version>
+ <configuration>
+ <source>1.5</source>
+ <target>1.5</target>
+ </configuration>
+ </plugin>
+ <plugin>
+ <groupId>org.apache.maven.plugins</groupId>
+ <artifactId>maven-surefire-plugin</artifactId>
+ <version>2.6</version>
+ </plugin>
+ <plugin>
+ <groupId>org.apache.maven.plugins</groupId>
+ <artifactId>maven-resources-plugin</artifactId>
+ <version>2.4.3</version>
+ </plugin>
+ <plugin>
+ <groupId>org.apache.maven.plugins</groupId>
+ <artifactId>maven-assembly-plugin</artifactId>
+ <version>2.2-beta-5</version>
+ <configuration>
+ <attach>false</attach>
+ <descriptors>
+ <descriptor>
+ src/assemble/release.xml
+ </descriptor>
+ </descriptors>
+ </configuration>
+ </plugin>
+ <plugin>
+ <groupId>org.apache.maven.plugins</groupId>
+ <artifactId>maven-release-plugin</artifactId>
+ <version>2.0</version>
+ <configuration>
+ <autoVersionSubmodules>true</autoVersionSubmodules>
+ <preparationGoals>clean install</preparationGoals>
+ <mavenExecutorId>forked-path</mavenExecutorId>
+ </configuration>
+ </plugin>
+ <plugin>
+ <groupId>org.codehaus.mojo</groupId>
+ <artifactId>javacc-maven-plugin</artifactId>
+ <version>2.6</version>
+ </plugin>
+ <plugin>
+ <groupId>org.codehaus.mojo</groupId>
+ <artifactId>exec-maven-plugin</artifactId>
+ <version>1.2</version>
+ </plugin>
+ <plugin>
+ <groupId>org.apache.maven.plugins</groupId>
+ <artifactId>maven-site-plugin</artifactId>
+ <version>2.1</version>
+ </plugin>
+ </plugins>
+ </pluginManagement>
+ <plugins>
<plugin>
+ <groupId>org.apache.maven.plugins</groupId>
+ <artifactId>maven-toolchains-plugin</artifactId>
+ <version>1.0</version>
+ <executions>
+ <execution>
+ <phase>validate</phase>
+ <goals>
+ <goal>toolchain</goal>
+ </goals>
+ </execution>
+ </executions>
+ <configuration>
+ <toolchains>
+ <jdk>
+ <version>1.5</version>
+ <vendor>sun</vendor>
+ </jdk>
+ </toolchains>
+ </configuration>
+ </plugin>
+ <plugin>
<groupId>com.mycila.maven-license-plugin</groupId>
<artifactId>maven-license-plugin</artifactId>
<version>1.6.1</version>
@@ -279,99 +308,77 @@
</execution>
</executions>
</plugin>
- </plugins>
- <pluginManagement>
- <plugins>
- <plugin>
- <inherited>true</inherited>
- <groupId>org.codehaus.mojo</groupId>
- <artifactId>javacc-maven-plugin</artifactId>
- <version>2.6</version>
- </plugin>
- <plugin>
- <inherited>true</inherited>
- <groupId>org.codehaus.mojo</groupId>
- <artifactId>exec-maven-plugin</artifactId>
- <version>1.2</version>
- </plugin>
- <plugin>
- <inherited>true</inherited>
- <groupId>org.apache.maven.plugins</groupId>
- <artifactId>maven-site-plugin</artifactId>
- <version>2.1</version>
- </plugin>
- </plugins>
- </pluginManagement>
- </build>
- <properties>
- <topDirectoryLocation>.</topDirectoryLocation>
- <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
- </properties>
- <dependencyManagement>
- <dependencies>
- <dependency>
- <groupId>junit</groupId>
- <artifactId>junit</artifactId>
- <version>4.8.2</version>
- </dependency>
- <dependency>
- <groupId>junitperf</groupId>
- <artifactId>junitperf</artifactId>
- <version>1.8</version>
- </dependency>
- <dependency>
- <groupId>org.mortbay.jetty</groupId>
- <artifactId>jetty</artifactId>
- <version>6.1.12</version>
- </dependency>
- <dependency>
- <groupId>commons-fileupload</groupId>
- <artifactId>commons-fileupload</artifactId>
- <version>1.2</version>
- </dependency>
- <dependency>
- <groupId>commons-io</groupId>
- <artifactId>commons-io</artifactId>
- <version>1.4</version>
- </dependency>
- <dependency>
- <groupId>net.sourceforge.htmlunit</groupId>
- <artifactId>htmlunit</artifactId>
- <version>2.8</version>
- </dependency>
- <dependency>
- <groupId>org.seleniumhq.selenium.client-drivers</groupId>
- <artifactId>selenium-java-client-driver</artifactId>
- <version>1.0.1</version>
- </dependency>
- <dependency>
- <groupId>regexp</groupId>
- <artifactId>regexp</artifactId>
- <version>1.3</version>
- </dependency>
- <dependency>
- <groupId>javax.servlet</groupId>
- <artifactId>servlet-api</artifactId>
- <version>2.4</version>
- </dependency>
- <dependency>
- <groupId>org.slf4j</groupId>
- <artifactId>slf4j-api</artifactId>
- <version>1.6.1</version>
- </dependency>
+ </plugins>
+ </build>
+ <properties>
+ <topDirectoryLocation>.</topDirectoryLocation>
+ <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
+ </properties>
+ <dependencyManagement>
+ <dependencies>
<dependency>
+ <groupId>junit</groupId>
+ <artifactId>junit</artifactId>
+ <version>4.8.2</version>
+ </dependency>
+ <dependency>
+ <groupId>junitperf</groupId>
+ <artifactId>junitperf</artifactId>
+ <version>1.8</version>
+ </dependency>
+ <dependency>
+ <groupId>org.mortbay.jetty</groupId>
+ <artifactId>jetty</artifactId>
+ <version>6.1.21</version>
+ </dependency>
+ <dependency>
+ <groupId>commons-fileupload</groupId>
+ <artifactId>commons-fileupload</artifactId>
+ <version>1.2.2</version>
+ </dependency>
+ <dependency>
+ <groupId>commons-io</groupId>
+ <artifactId>commons-io</artifactId>
+ <version>1.4</version>
+ </dependency>
+ <dependency>
+ <groupId>net.sourceforge.htmlunit</groupId>
+ <artifactId>htmlunit</artifactId>
+ <version>2.8</version>
+ </dependency>
+ <dependency>
+ <groupId>org.seleniumhq.selenium.client-drivers</groupId>
+ <artifactId>selenium-java-client-driver</artifactId>
+ <version>1.0.1</version>
+ </dependency>
+ <dependency>
+ <groupId>regexp</groupId>
+ <artifactId>regexp</artifactId>
+ <version>1.3</version>
+ </dependency>
+ <dependency>
+ <groupId>javax.servlet</groupId>
+ <artifactId>servlet-api</artifactId>
+ <version>2.5</version>
+ </dependency>
+ <dependency>
<groupId>org.slf4j</groupId>
+ <artifactId>slf4j-api</artifactId>
+ <version>1.6.1</version>
+ </dependency>
+ <dependency>
+ <groupId>org.slf4j</groupId>
<artifactId>jcl-over-slf4j</artifactId>
<version>1.6.1</version>
</dependency>
- <dependency>
- <groupId>ch.qos.logback</groupId>
- <artifactId>logback-classic</artifactId>
- <version>0.9.24</version>
- <optional>true</optional>
- </dependency>
- </dependencies>
- </dependencyManagement>
+ <dependency>
+ <groupId>ch.qos.logback</groupId>
+ <artifactId>logback-classic</artifactId>
+ <version>0.9.24</version>
+ <optional>true</optional>
+ </dependency>
+ </dependencies>
+ </dependencyManagement>
<profiles>
<profile>
<id>release-sign-artifacts</id>
@@ -401,168 +408,168 @@
</build>
</profile>
</profiles>
- <reporting>
- <plugins>
- <plugin>
- <groupId>org.apache.maven.plugins</groupId>
- <artifactId>maven-checkstyle-plugin</artifactId>
- <version>2.5</version>
- <configuration>
- <configLocation>
- ${basedir}/${topDirectoryLocation}/src/checkstyle/jwebunit-checkstyle.xml
- </configLocation>
- <headerLocation>
- ${basedir}/${topDirectoryLocation}/src/checkstyle/header-checkstyle.txt
- </headerLocation>
- <xrefLocation>xref</xrefLocation>
- </configuration>
- </plugin>
- <plugin>
- <groupId>org.apache.maven.plugins</groupId>
- <artifactId>maven-surefire-report-plugin</artifactId>
- <version>2.4.3</version>
- </plugin>
- <plugin>
- <groupId>org.codehaus.mojo</groupId>
- <artifactId>jdepend-maven-plugin</artifactId>
- <version>2.0-beta-2</version>
- </plugin>
- <plugin>
- <groupId>org.apache.maven.plugins</groupId>
- <artifactId>maven-changes-plugin</artifactId>
- <version>2.2</version>
- <inherited>false</inherited>
- <reportSets>
- <reportSet>
- <reports>
- <report>changes-report</report>
- </reports>
- </reportSet>
- </reportSets>
- <configuration>
- <issueLinkTemplate>
- http://sourceforge.net/support/tracker.php?aid=%ISSUE%
- </issueLinkTemplate>
- </configuration>
- </plugin>
- <plugin>
- <groupId>org.codehaus.mojo</groupId>
- <artifactId>findbugs-maven-plugin</artifactId>
- <version>2.3.1</version>
- </plugin>
- <plugin>
- <groupId>org.apache.maven.plugins</groupId>
- <artifactId>maven-javadoc-plugin</artifactId>
- <version>2.6.1</version>
- <reportSets>
- <reportSet>
- <id>aggregate</id>
- <configuration>
- <excludePackageNames>
- net.sourceforge.jwebunit.javacc:net.sourceforge.jwebunit.tests
- </excludePackageNames>
- <links>
- <link>
- http://java.sun.com/j2se/1.5.0/docs/api/
- </link>
- <link>
- http://hc.apache.org/httpclient-3.x/apidocs/
- </link>
- <link>http://junit.sourceforge.net/junit3.8.1/javadoc/</link>
- <link>
- http://htmlunit.sourceforge.net/apidocs/
- </link>
- <link>http://release.seleniumhq.org/selenium-remote-control/0.9.2/doc/java/</link>
- </links>
- <groups>
- <group>
- <title>Core Packages</title>
- <packages>
- net.sourceforge.jwebunit.api*:net.sourceforge.jwebunit.junit*:net.sourceforge.jwebunit.exception*:net.sourceforge.jwebunit.html*:net.sourceforge.jwebunit.javascript*:net.sourceforge.jwebunit.util*
- </packages>
- </group>
- <group>
- <title>HtmlUnit Packages</title>
- <packages>
- net.sourceforge.jwebunit.htmlunit*
- </packages>
- </group>
- <group>
- <title>Selenium Packages</title>
- <packages>
- net.sourceforge.jwebunit.selenium*
- </packages>
- </group>
- </groups>
- </configuration>
- <reports>
- <report>aggregate</report>
- </reports>
- </reportSet>
- </reportSets>
- </plugin>
- <plugin>
- <groupId>org.apache.maven.plugins</groupId>
- <artifactId>maven-jxr-plugin</artifactId>
- <version>2.1</version>
- <configuration>
- <aggregate>true</aggregate>
- </configuration>
- </plugin>
- <plugin>
- <groupId>org.codehaus.mojo</groupId>
- <artifactId>taglist-maven-plugin</artifactId>
- <version>2.4</version>
- </plugin>
- <plugin>
- <groupId>org.apache.maven.plugins</groupId>
- <artifactId>maven-pmd-plugin</artifactId>
- <version>2.4</version>
- <configuration>
- <xrefLocation>
- ${project.reporting.outputDirectory}/${topDirectoryLocation}/xref
- </xrefLocation>
- <targetJdk>1.5</targetJdk>
- </configuration>
- </plugin>
- <plugin>
- <groupId>org.apache.maven.plugins</groupId>
- <artifactId>maven-project-info-reports-plugin</artifactId>
- <version>2.2</version>
- <reportSets>
- <reportSet>
- <reports>
- <report>index</report>
- <report>dependencies</report>
- <report>project-team</report>
- <report>mailing-list</report>
- <report>license</report>
- <report>issue-tracking</report>
- <report>scm</report>
- <report>summary</report>
- </reports>
- </reportSet>
- </reportSets>
- </plugin>
- </plugins>
- </reporting>
- <distributionManagement>
- <site>
- <id>jwebunit-website</id>
- <name>JWebUnit WebSite - Sourceforge</name>
- <url>
- scp://shell.sourceforge.net/home/groups/j/jw/jwebunit/htdocs
- </url>
- </site>
- <snapshotRepository>
- <id>sonatype-nexus</id>
- <url>http://oss.sonatype.org/content/repositories/snapshots</url>
- <name>Sonatype Nexus OSS Snapshot Repository</name>
- </snapshotRepository>
- <repository>
- <id>sonatype-nexus</id>
- <url>http://oss.sonatype.org/service/local/staging/deploy/maven2</url>
- <name>Sonatype Nexus OSS Staging Repository</name>
- </repository>
- </distributionManagement>
+ <reporting>
+ <plugins>
+ <plugin>
+ <groupId>org.apache.maven.plugins</groupId>
+ <artifactId>maven-checkstyle-plugin</artifactId>
+ <version>2.5</version>
+ <configuration>
+ <configLocation>
+ ${basedir}/${topDirectoryLocation}/src/checkstyle/jwebunit-checkstyle.xml
+ </configLocation>
+ <headerLocation>
+ ${basedir}/${topDirectoryLocation}/src/checkstyle/header-checkstyle.txt
+ </headerLocation>
+ <xrefLocation>xref</xrefLocation>
+ </configuration>
+ </plugin>
+ <plugin>
+ <groupId>org.apache.maven.plugins</groupId>
+ <artifactId>maven-surefire-report-plugin</artifactId>
+ <version>2.4.3</version>
+ </plugin>
+ <plugin>
+ <groupId>org.codehaus.mojo</groupId>
+ <artifactId>jdepend-maven-plugin</artifactId>
+ <version>2.0-beta-2</version>
+ </plugin>
+ <plugin>
+ <groupId>org.apache.maven.plugins</groupId>
+ <artifactId>maven-changes-plugin</artifactId>
+ <version>2.2</version>
+ <inherited>false</inherited>
+ <reportSets>
+ <reportSet>
+ <reports>
+ <report>changes-report</report>
+ </reports>
+ </reportSet>
+ </reportSets>
+ <configuration>
+ <issueLinkTemplate>
+ http://sourceforge.net/support/tracker.php?aid=%ISSUE%
+ </issueLinkTemplate>
+ </configuration>
+ </plugin>
+ <plugin>
+ <groupId>org.codehaus.mojo</groupId>
+ <artifactId>findbugs-maven-plugin</artifactId>
+ <version>2.3.1</version>
+ </plugin>
+ <plugin>
+ <groupId>org.apache.maven.plugins</groupId>
+ <artifactId>maven-javadoc-plugin</artifactId>
+ <version>2.6.1</version>
+ <reportSets>
+ <reportSet>
+ <id>aggregate</id>
+ <configuration>
+ <excludePackageNames>
+ net.sourceforge.jwebunit.javacc:net.sourceforge.jwebunit.tests
+ </excludePackageNames>
+ <links>
+ <link>
+ http://java.sun.com/j2se/1.5.0/docs/api/
+ </link>
+ <link>
+ http://hc.apache.org/httpclient-3.x/apidocs/
+ </link>
+ <link>http://junit.sourceforge.net/junit3.8.1/javadoc/</link>
+ <link>
+ http://htmlunit.sourceforge.net/apidocs/
+ </link>
+ <link>http://release.seleniumhq.org/selenium-remote-control/0.9.2/doc/java/</link>
+ </links>
+ <groups>
+ <group>
+ <title>Core Packages</title>
+ <packages>
+ net.sourceforge.jwebunit.api*:net.sourceforge.jwebunit.junit*:net.sourceforge.jwebunit.exception*:net.sourceforge.jwebunit.html*:net.sourceforge.jwebunit.javascript*:net.sourceforge.jwebunit.util*
+ </packages>
+ </group>
+ <group>
+ <title>HtmlUnit Packages</title>
+ <packages>
+ net.sourceforge.jwebunit.htmlunit*
+ </packages>
+ </group>
+ <group>
+ <title>Selenium Packages</title>
+ <packages>
+ net.sourceforge.jwebunit.selenium*
+ </packages>
+ </group>
+ </groups>
+ </configuration>
+ <reports>
+ <report>aggregate</report>
+ </reports>
+ </reportSet>
+ </reportSets>
+ </plugin>
+ <plugin>
+ <groupId>org.apache.maven.plugins</groupId>
+ <artifactId>maven-jxr-plugin</artifactId>
+ <version>2.1</version>
+ <configuration>
+ <aggregate>true</aggregate>
+ </configuration>
+ </plugin>
+ <plugin>
+ <groupId>org.codehaus.mojo</groupId>
+ <artifactId>taglist-maven-plugin</artifactId>
+ <version>2.4</version>
+ </plugin>
+ <plugin>
+ <groupId>org.apache.maven.plugins</groupId>
+ <artifactId>maven-pmd-plugin</artifactId>
+ <version>2.4</version>
+ <configuration>
+ <xrefLocation>
+ ${project.reporting.outputDirectory}/${topDirectoryLocation}/xref
+ </xrefLocation>
+ <targetJdk>1.5</targetJdk>
+ </configuration>
+ </plugin>
+ <plugin>
+ <groupId>org.apache.maven.plugins</groupId>
+ <artifactId>maven-project-info-reports-plugin</artifactId>
+ <version>2.2</version>
+ <reportSets>
+ <reportSet>
+ <reports>
+ <report>index</report>
+ <report>dependencies</report>
+ <report>project-team</report>
+ <report>mailing-list</report>
+ <report>license</report>
+ <report>issue-tracking</report>
+ <report>scm</report>
+ <report>summary</report>
+ </reports>
+ </reportSet>
+ </reportSets>
+ </plugin>
+ </plugins>
+ </reporting>
+ <distributionManagement>
+ <site>
+ <id>jwebunit-website</id>
+ <name>JWebUnit WebSite - Sourceforge</name>
+ <url>
+ scp://shell.sourceforge.net/home/groups/j/jw/jwebunit/htdocs
+ </url>
+ </site>
+ <snapshotRepository>
+ <id>sonatype-nexus</id>
+ <url>http://oss.sonatype.org/content/repositories/snapshots</url>
+ <name>Sonatype Nexus OSS Snapshot Repository</name>
+ </snapshotRepository>
+ <repository>
+ <id>sonatype-nexus</id>
+ <url>http://oss.sonatype.org/service/local/staging/deploy/maven2</url>
+ <name>Sonatype Nexus OSS Staging Repository</name>
+ </repository>
+ </distributionManagement>
</project>
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <he...@us...> - 2010-10-05 11:48:15
|
Revision: 848
http://jwebunit.svn.sourceforge.net/jwebunit/?rev=848&view=rev
Author: henryju
Date: 2010-10-05 11:48:08 +0000 (Tue, 05 Oct 2010)
Log Message:
-----------
Updated Maven plugins.
Modified Paths:
--------------
trunk/jwebunit-webtestcase-generator/src/main/javacc/Token.java
trunk/pom.xml
Modified: trunk/jwebunit-webtestcase-generator/src/main/javacc/Token.java
===================================================================
--- trunk/jwebunit-webtestcase-generator/src/main/javacc/Token.java 2010-10-05 11:30:35 UTC (rev 847)
+++ trunk/jwebunit-webtestcase-generator/src/main/javacc/Token.java 2010-10-05 11:48:08 UTC (rev 848)
@@ -17,27 +17,38 @@
* along with JWebUnit. If not, see <http://www.gnu.org/licenses/>.
*/
-/* Generated By:JavaCC: Do not edit this line. Token.java Version 3.0 */
+/* Generated By:JavaCC: Do not edit this line. Token.java Version 5.0 */
+/* JavaCCOptions:TOKEN_EXTENDS=,KEEP_LINE_COL=null,SUPPORT_CLASS_VISIBILITY_PUBLIC=true */
package net.sourceforge.jwebunit.javacc;
+
/**
* Describes the input token stream.
*/
-public class Token {
+public class Token implements java.io.Serializable {
/**
+ * The version identifier for this Serializable class.
+ * Increment only if the <i>serialized</i> form of the
+ * class changes.
+ */
+ private static final long serialVersionUID = 1L;
+
+ /**
* An integer that describes the kind of this token. This numbering
* system is determined by JavaCCParser, and a table of these numbers is
* stored in the file ...Constants.java.
*/
public int kind;
- /**
- * beginLine and beginColumn describe the position of the first character
- * of this token; endLine and endColumn describe the position of the
- * last character of this token.
- */
- public int beginLine, beginColumn, endLine, endColumn;
+ /** The line number of the first character of this Token. */
+ public int beginLine;
+ /** The column number of the first character of this Token. */
+ public int beginColumn;
+ /** The line number of the last character of this Token. */
+ public int endLine;
+ /** The column number of the last character of this Token. */
+ public int endColumn;
/**
* The string image of the token.
@@ -69,11 +80,45 @@
public Token specialToken;
/**
+ * An optional attribute value of the Token.
+ * Tokens which are not used as syntactic sugar will often contain
+ * meaningful values that will be used later on by the compiler or
+ * interpreter. This attribute value is often different from the image.
+ * Any subclass of Token that actually wants to return a non-null value can
+ * override this method as appropriate.
+ */
+ public Object getValue() {
+ return null;
+ }
+
+ /**
+ * No-argument constructor
+ */
+ public Token() {}
+
+ /**
+ * Constructs a new token for the specified Image.
+ */
+ public Token(int kind)
+ {
+ this(kind, null);
+ }
+
+ /**
+ * Constructs a new token for the specified Image and Kind.
+ */
+ public Token(int kind, String image)
+ {
+ this.kind = kind;
+ this.image = image;
+ }
+
+ /**
* Returns the image.
*/
public String toString()
{
- return image;
+ return image;
}
/**
@@ -81,27 +126,37 @@
* can create and return subclass objects based on the value of ofKind.
* Simply add the cases to the switch for all those special cases.
* For example, if you have a subclass of Token called IDToken that
- * you want to create if ofKind is ID, simlpy add something like :
+ * you want to create if ofKind is ID, simply add something like :
*
- * case MyParserConstants.ID : return new IDToken();
+ * case MyParserConstants.ID : return new IDToken(ofKind, image);
*
* to the following switch statement. Then you can cast matchedToken
- * variable to the appropriate type and use it in your lexical actions.
+ * variable to the appropriate type and use sit in your lexical actions.
*/
- public static final Token newToken(int ofKind)
+ public static Token newToken(int ofKind, String image)
{
- switch(ofKind)
- {
- default : return new Token();
- case WebTestCaseGeneratorConstants.RUNSIGNEDSHIFT:
- case WebTestCaseGeneratorConstants.RSIGNEDSHIFT:
- case WebTestCaseGeneratorConstants.GT:
- return new GTToken();
- }
+ switch(ofKind)
+ {
+ case WebTestCaseGeneratorConstants.RUNSIGNEDSHIFT:
+ case WebTestCaseGeneratorConstants.RSIGNEDSHIFT:
+ case WebTestCaseGeneratorConstants.GT:
+ return new GTToken(ofKind, image);
+ default : return new Token(ofKind, image);
+ }
}
+ public static Token newToken(int ofKind)
+ {
+ return newToken(ofKind, null);
+ }
+
public static class GTToken extends Token
{
int realKind = WebTestCaseGeneratorConstants.GT;
+
+ public GTToken(int ofKind, String image) {
+ super(ofKind, image);
+ }
}
}
+/* JavaCC - OriginalChecksum=609da7eefb5a4f2a594508df0fe19464 (do not edit this line) */
Modified: trunk/pom.xml
===================================================================
--- trunk/pom.xml 2010-10-05 11:30:35 UTC (rev 847)
+++ trunk/pom.xml 2010-10-05 11:48:08 UTC (rev 848)
@@ -200,7 +200,7 @@
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-assembly-plugin</artifactId>
- <version>2.2-beta-2</version>
+ <version>2.2-beta-5</version>
<configuration>
<attach>false</attach>
<descriptors>
@@ -223,7 +223,7 @@
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-compiler-plugin</artifactId>
- <version>2.1</version>
+ <version>2.3.2</version>
<configuration>
<source>1.5</source>
<target>1.5</target>
@@ -253,7 +253,7 @@
<plugin>
<groupId>com.mycila.maven-license-plugin</groupId>
<artifactId>maven-license-plugin</artifactId>
- <version>1.6.0</version>
+ <version>1.6.1</version>
<configuration>
<header>${topDirectoryLocation}/src/license/header.txt</header>
<aggregate>false</aggregate>
@@ -286,13 +286,13 @@
<inherited>true</inherited>
<groupId>org.codehaus.mojo</groupId>
<artifactId>javacc-maven-plugin</artifactId>
- <version>2.4</version>
+ <version>2.6</version>
</plugin>
<plugin>
<inherited>true</inherited>
<groupId>org.codehaus.mojo</groupId>
<artifactId>exec-maven-plugin</artifactId>
- <version>1.1-beta-1</version>
+ <version>1.2</version>
</plugin>
<plugin>
<inherited>true</inherited>
@@ -386,7 +386,7 @@
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-gpg-plugin</artifactId>
- <version>1.0</version>
+ <version>1.1</version>
<executions>
<execution>
<id>sign-artifacts</id>
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <he...@us...> - 2010-10-05 11:30:42
|
Revision: 847
http://jwebunit.svn.sourceforge.net/jwebunit/?rev=847&view=rev
Author: henryju
Date: 2010-10-05 11:30:35 +0000 (Tue, 05 Oct 2010)
Log Message:
-----------
Replaced log4j by logback for test suite.
Modified Paths:
--------------
trunk/jwebunit-htmlunit-plugin/pom.xml
trunk/jwebunit-selenium-plugin/pom.xml
trunk/pom.xml
Added Paths:
-----------
trunk/jwebunit-commons-tests/src/main/resources/logback-test.xml
Removed Paths:
-------------
trunk/jwebunit-commons-tests/src/main/resources/log4j.properties
Deleted: trunk/jwebunit-commons-tests/src/main/resources/log4j.properties
===================================================================
--- trunk/jwebunit-commons-tests/src/main/resources/log4j.properties 2010-10-05 10:30:48 UTC (rev 846)
+++ trunk/jwebunit-commons-tests/src/main/resources/log4j.properties 2010-10-05 11:30:35 UTC (rev 847)
@@ -1,45 +0,0 @@
-#
-# Copyright (c) 2010, JWebUnit team.
-#
-# This file is part of JWebUnit.
-#
-# JWebUnit is free software: you can redistribute it and/or modify
-# it under the terms of the GNU Lesser General Public License as published by
-# the Free Software Foundation, either version 3 of the License, or
-# (at your option) any later version.
-#
-# JWebUnit is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU General Public License for more details.
-#
-# You should have received a copy of the GNU Lesser General Public License
-# along with JWebUnit. If not, see <http://www.gnu.org/licenses/>.
-#
-
-log4j.rootLogger=DEBUG, consoleAppender
-
-# consoleAppender is set to be a ConsoleAppender which outputs to System.out.
-log4j.appender.consoleAppender=org.apache.log4j.ConsoleAppender
-log4j.appender.consoleAppender.Target=System.out
-log4j.appender.consoleAppender.layout=org.apache.log4j.PatternLayout
-log4j.appender.consoleAppender.layout.ConversionPattern=%-4r %-5p %x [%t] %15c : %m%n
-
-
-#jwebunit
-log4j.logger.net.sourceforge.jwebunit=ERROR
-
-#htmlunit
-log4j.logger.com.gargoylesoftware=ERROR
-log4j.logger.com.gargoylesoftware.javascript=ERROR
-
-#httpclient
-log4j.logger.org.apache.commons.httpclient=ERROR
-log4j.logger.org.apache.http=ERROR
-
-#mime4j
-log4j.logger.org.apache.james.mime4j=ERROR
-
-
-#Jetty
-log4j.logger.org.mortbay=ERROR
Added: trunk/jwebunit-commons-tests/src/main/resources/logback-test.xml
===================================================================
--- trunk/jwebunit-commons-tests/src/main/resources/logback-test.xml (rev 0)
+++ trunk/jwebunit-commons-tests/src/main/resources/logback-test.xml 2010-10-05 11:30:35 UTC (rev 847)
@@ -0,0 +1,48 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+
+ Copyright (c) 2010, JWebUnit team.
+
+ This file is part of JWebUnit.
+
+ JWebUnit is free software: you can redistribute it and/or modify
+ it under the terms of the GNU Lesser General Public License as published by
+ the Free Software Foundation, either version 3 of the License, or
+ (at your option) any later version.
+
+ JWebUnit is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public License
+ along with JWebUnit. If not, see <http://www.gnu.org/licenses/>.
+
+-->
+
+<configuration>
+ <appender name="consoleAppender" class="ch.qos.logback.core.ConsoleAppender">
+ <Target>System.out</Target>
+ <encoder>
+ <pattern>%d{HH:mm:ss.SSS} %-5level %logger{36} - %msg%n</pattern>
+ </encoder>
+ </appender>
+
+ <logger name="net.sourceforge.jwebunit" level="ERROR"/>
+
+ <logger name="com.gargoylesoftware" level="ERROR"/>
+ <logger name="com.gargoylesoftware.javascript" level="ERROR"/>
+
+ <logger name="org.apache.james.mime4j" level="ERROR"/>
+
+ <logger name="org.apache.commons.httpclient" level="ERROR"/>
+ <logger name="org.apache.http" level="ERROR"/>
+
+ <logger name="org.mortbay" level="ERROR"/>
+
+ <logger name="ch.qos.logback" level="ERROR"/>
+
+ <root level="DEBUG">
+ <appender-ref ref="consoleAppender"/>
+ </root>
+</configuration>
Property changes on: trunk/jwebunit-commons-tests/src/main/resources/logback-test.xml
___________________________________________________________________
Added: svn:mime-type
+ text/plain
Modified: trunk/jwebunit-htmlunit-plugin/pom.xml
===================================================================
--- trunk/jwebunit-htmlunit-plugin/pom.xml 2010-10-05 10:30:48 UTC (rev 846)
+++ trunk/jwebunit-htmlunit-plugin/pom.xml 2010-10-05 11:30:35 UTC (rev 847)
@@ -70,8 +70,8 @@
<artifactId>jcl-over-slf4j</artifactId>
</dependency>
<dependency>
- <groupId>org.slf4j</groupId>
- <artifactId>slf4j-log4j12</artifactId>
+ <groupId>ch.qos.logback</groupId>
+ <artifactId>logback-classic</artifactId>
</dependency>
<dependency>
<groupId>javax.servlet</groupId>
Modified: trunk/jwebunit-selenium-plugin/pom.xml
===================================================================
--- trunk/jwebunit-selenium-plugin/pom.xml 2010-10-05 10:30:48 UTC (rev 846)
+++ trunk/jwebunit-selenium-plugin/pom.xml 2010-10-05 11:30:35 UTC (rev 847)
@@ -81,8 +81,8 @@
<artifactId>slf4j-api</artifactId>
</dependency>
<dependency>
- <groupId>org.slf4j</groupId>
- <artifactId>slf4j-log4j12</artifactId>
+ <groupId>ch.qos.logback</groupId>
+ <artifactId>logback-classic</artifactId>
</dependency>
<dependency>
<groupId>javax.servlet</groupId>
Modified: trunk/pom.xml
===================================================================
--- trunk/pom.xml 2010-10-05 10:30:48 UTC (rev 846)
+++ trunk/pom.xml 2010-10-05 11:30:35 UTC (rev 847)
@@ -365,9 +365,9 @@
<version>1.6.1</version>
</dependency>
<dependency>
- <groupId>org.slf4j</groupId>
- <artifactId>slf4j-log4j12</artifactId>
- <version>1.6.1</version>
+ <groupId>ch.qos.logback</groupId>
+ <artifactId>logback-classic</artifactId>
+ <version>0.9.24</version>
<optional>true</optional>
</dependency>
</dependencies>
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <he...@us...> - 2010-10-05 10:30:55
|
Revision: 846
http://jwebunit.svn.sourceforge.net/jwebunit/?rev=846&view=rev
Author: henryju
Date: 2010-10-05 10:30:48 +0000 (Tue, 05 Oct 2010)
Log Message:
-----------
Updated to HtmlUnit 2.8 and to slf4j 1.6.1.
Modified Paths:
--------------
trunk/jwebunit-commons-tests/src/main/resources/log4j.properties
trunk/jwebunit-htmlunit-plugin/pom.xml
trunk/jwebunit-htmlunit-plugin/src/main/java/net/sourceforge/jwebunit/htmlunit/HtmlUnitTestingEngineImpl.java
trunk/pom.xml
trunk/src/changes/changes.xml
Modified: trunk/jwebunit-commons-tests/src/main/resources/log4j.properties
===================================================================
--- trunk/jwebunit-commons-tests/src/main/resources/log4j.properties 2010-10-05 10:13:43 UTC (rev 845)
+++ trunk/jwebunit-commons-tests/src/main/resources/log4j.properties 2010-10-05 10:30:48 UTC (rev 846)
@@ -35,7 +35,11 @@
#httpclient
log4j.logger.org.apache.commons.httpclient=ERROR
-log4j.logger.httpclient.wire=ERROR
+log4j.logger.org.apache.http=ERROR
+#mime4j
+log4j.logger.org.apache.james.mime4j=ERROR
+
+
#Jetty
log4j.logger.org.mortbay=ERROR
Modified: trunk/jwebunit-htmlunit-plugin/pom.xml
===================================================================
--- trunk/jwebunit-htmlunit-plugin/pom.xml 2010-10-05 10:13:43 UTC (rev 845)
+++ trunk/jwebunit-htmlunit-plugin/pom.xml 2010-10-05 10:30:48 UTC (rev 846)
@@ -43,6 +43,12 @@
<dependency>
<groupId>net.sourceforge.htmlunit</groupId>
<artifactId>htmlunit</artifactId>
+ <exclusions>
+ <exclusion>
+ <artifactId>commons-logging</artifactId>
+ <groupId>commons-logging</groupId>
+ </exclusion>
+ </exclusions>
</dependency>
<dependency>
<groupId>net.sourceforge.jwebunit</groupId>
@@ -61,6 +67,10 @@
</dependency>
<dependency>
<groupId>org.slf4j</groupId>
+ <artifactId>jcl-over-slf4j</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.slf4j</groupId>
<artifactId>slf4j-log4j12</artifactId>
</dependency>
<dependency>
Modified: trunk/jwebunit-htmlunit-plugin/src/main/java/net/sourceforge/jwebunit/htmlunit/HtmlUnitTestingEngineImpl.java
===================================================================
--- trunk/jwebunit-htmlunit-plugin/src/main/java/net/sourceforge/jwebunit/htmlunit/HtmlUnitTestingEngineImpl.java 2010-10-05 10:13:43 UTC (rev 845)
+++ trunk/jwebunit-htmlunit-plugin/src/main/java/net/sourceforge/jwebunit/htmlunit/HtmlUnitTestingEngineImpl.java 2010-10-05 10:30:48 UTC (rev 846)
@@ -300,7 +300,7 @@
c.setMaxAge(second.intValue());
}
c.setPath(cookie.getPath());
- c.setSecure(cookie.toHttpClient().getSecure());
+ c.setSecure(cookie.toHttpClient().isSecure());
c.setVersion(cookie.toHttpClient().getVersion());
result.add(c);
}
@@ -735,12 +735,8 @@
}
public InputStream getInputStream() {
- try {
- return wc.getCurrentWindow().getEnclosedPage().getWebResponse()
- .getContentAsStream();
- } catch (IOException e) {
- throw new RuntimeException(e);
- }
+ return wc.getCurrentWindow().getEnclosedPage().getWebResponse()
+ .getContentAsStream();
}
public InputStream getInputStream(URL resourceUrl)
@@ -755,9 +751,6 @@
} catch (FailingHttpStatusCodeException aException) {
throw new TestingEngineResponseException(
aException.getStatusCode(), aException);
-
- } catch (IOException aException) {
- throw new RuntimeException(aException);
} finally {
if (imageWindow != null) {
wc.deregisterWebWindow(imageWindow);
Modified: trunk/pom.xml
===================================================================
--- trunk/pom.xml 2010-10-05 10:13:43 UTC (rev 845)
+++ trunk/pom.xml 2010-10-05 10:30:48 UTC (rev 846)
@@ -337,7 +337,7 @@
<dependency>
<groupId>net.sourceforge.htmlunit</groupId>
<artifactId>htmlunit</artifactId>
- <version>2.7</version>
+ <version>2.8</version>
</dependency>
<dependency>
<groupId>org.seleniumhq.selenium.client-drivers</groupId>
@@ -357,12 +357,17 @@
<dependency>
<groupId>org.slf4j</groupId>
<artifactId>slf4j-api</artifactId>
- <version>1.5.0</version>
+ <version>1.6.1</version>
</dependency>
+ <dependency>
+ <groupId>org.slf4j</groupId>
+ <artifactId>jcl-over-slf4j</artifactId>
+ <version>1.6.1</version>
+ </dependency>
<dependency>
<groupId>org.slf4j</groupId>
<artifactId>slf4j-log4j12</artifactId>
- <version>1.5.0</version>
+ <version>1.6.1</version>
<optional>true</optional>
</dependency>
</dependencies>
Modified: trunk/src/changes/changes.xml
===================================================================
--- trunk/src/changes/changes.xml 2010-10-05 10:13:43 UTC (rev 845)
+++ trunk/src/changes/changes.xml 2010-10-05 10:30:48 UTC (rev 846)
@@ -30,6 +30,12 @@
<body>
<release version="2.5" date="UNKNOW" description="">
<action type="update" dev="henryju">
+ Updated to slf4j 1.6.1.
+ </action>
+ <action type="update" dev="henryju">
+ Updated to HtmlUnit 2.8.
+ </action>
+ <action type="update" dev="henryju">
Updated to JUnit 4.8.2.
</action>
<action type="add" dev="henryju" issue="1864365" due-to="Jason McSwain">
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <he...@us...> - 2010-10-05 10:13:49
|
Revision: 845
http://jwebunit.svn.sourceforge.net/jwebunit/?rev=845&view=rev
Author: henryju
Date: 2010-10-05 10:13:43 +0000 (Tue, 05 Oct 2010)
Log Message:
-----------
Updated to JUnit 4.8.2.
Modified Paths:
--------------
trunk/pom.xml
trunk/src/changes/changes.xml
Modified: trunk/pom.xml
===================================================================
--- trunk/pom.xml 2010-09-14 12:08:58 UTC (rev 844)
+++ trunk/pom.xml 2010-10-05 10:13:43 UTC (rev 845)
@@ -312,7 +312,7 @@
<dependency>
<groupId>junit</groupId>
<artifactId>junit</artifactId>
- <version>4.7</version>
+ <version>4.8.2</version>
</dependency>
<dependency>
<groupId>junitperf</groupId>
Modified: trunk/src/changes/changes.xml
===================================================================
--- trunk/src/changes/changes.xml 2010-09-14 12:08:58 UTC (rev 844)
+++ trunk/src/changes/changes.xml 2010-10-05 10:13:43 UTC (rev 845)
@@ -29,6 +29,9 @@
</properties>
<body>
<release version="2.5" date="UNKNOW" description="">
+ <action type="update" dev="henryju">
+ Updated to JUnit 4.8.2.
+ </action>
<action type="add" dev="henryju" issue="1864365" due-to="Jason McSwain">
Added the ability to change RefreshHandler in HtmlUnitTestingEngine.
</action>
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: SourceForge.net <no...@so...> - 2010-09-22 14:21:06
|
Feature Requests item #3073358, was opened at 2010-09-22 16:21 Message generated for change (Tracker Item Submitted) made by mauriziotodaro You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=497985&aid=3073358&group_id=61302 Please note that this message will contain a full copy of the comment thread, including the initial issue submission, for this request, not just the latest update. Category: Selenium plugin Group: None Status: Open Priority: 5 Private: No Submitted By: Maurizio Todaro (mauriziotodaro) Assigned to: Nobody/Anonymous (nobody) Summary: Change browser capability Initial Comment: In net.sourceforge.jwebunit.selenium.SeleniumTestingEngineImpl class the method beginAt use embedded browser key to call selenium server a get and set method my be usefull to provide this feature public void beginAt(URL aInitialURL, TestContext aTestContext) throws TestingEngineResponseException { 83 this.setTestContext(aTestContext); 84 selenium = new DefaultSelenium("localhost", port, "*chrome", aInitialURL.toString()); 85 selenium.start(); 86 gotoPage(aInitialURL); 87 } 88 ---------------------------------------------------------------------- You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=497985&aid=3073358&group_id=61302 |
Hi Jason, I have applied your patch. I moved test resources to the commons-test module because it was breaking nearly all other tests. Thanks, Julien > >De : Jason McSwain <jas...@gm...> >À : Julien HENRY <he...@ya...> >Envoyé le : Mar 7 septembre 2010, 17h 59min 40s >Objet : Re: Re : Re : Re : Attempted to refresh a page using an >ImmediateRefreshHandler which could have caused an OutOfMemoryError Please use >WaitingRefreshHandler or ThreadedRefreshHandler instead > >Hello Julien, > >I have attached the diff containing all changes, for your review. > >-Jason- > > >On Tue, Sep 7, 2010 at 2:02 AM, Julien HENRY <he...@ya...> wrote: > >svn diff contains new file as long as your do a svn add before. >> >>Regards, >> >>Julien >> >> >>> >>>De : Jason McSwain <jas...@gm...> >>>À : Julien HENRY <he...@ya...> >>>Envoyé le : Mar 7 septembre 2010, 5h 35min 53s >>>Objet : Re: Re : Re : Attempted to refresh a page using an >>>ImmediateRefreshHandler which could have caused an OutOfMemoryError Please use >>>WaitingRefreshHandler or ThreadedRefreshHandler instead >>> >>> >>> >>>Julien, >>> >>>Since svn diff does not include new files (AFAIK), what is the preferred way to >>>upload a patch that contains new files? >>> >>>-Jason- >>> >>> >>> >>>On Sun, Sep 5, 2010 at 11:45 AM, Julien HENRY <he...@ya...> wrote: >>> >>>Hi Jason, >>>> >>>> >>>>> what is the format that you would like to receive the changes (code + unit test >>>>>class + additional html resource file) >>>> >>>>A standard .patch file would be great (you can create one using svn patch >>>>command). >>>> >>>> >>>>> where the It would appear that i can reference HtmlUnitTestingEngineImpl from >>>>>inside the "jwebunit-commons-tests". >>>> >>>>You are right, there is a dependency issue because common-tests are designed to >>>>be independent of the testing engine. So this is the testing engine module that >>>>depends on common-tests. >>>> >>>>I will look at your work but I guess the best solution is to put this test that >>>>is very specific to HtmlUnit in HtmlUnit module. >>>> >>>>Regards, >>>> >>>>Julien >>>> >>>> >>>>> >>>>>De : Jason McSwain <jas...@gm...> >>>>>À : Julien HENRY <he...@ya...> >>>>>Envoyé le : Sam 4 septembre 2010, 0h 24min 20s >>>>>Objet : Re: Re : Attempted to refresh a page using an ImmediateRefreshHandler >>>>>which could have caused an OutOfMemoryError Please use WaitingRefreshHandler or >>>>>ThreadedRefreshHandler instead >>>>> >>>>> >>>>>Ok, next question: >>>>> >>>>>If i wanted to create a Test Class "RefreshHandlerTest" and an associated >>>>>resource, >>>>> >>>>> >>>>>I tried putting the test in the >>>>>"jwebunit-common-tests/src/test/java/net.sourceforge.jwebunit.tests.util.reflect" >>>>> >>>>>and i put the test html page into >>>>>"jwebunit-common-tests/src/main/resources/testcases/RefreshHandlerTest/testPage.html" >>>>> >>>>> >>>>>ive attached them, incase you want to give it a try yourself. >>>>> >>>>>My problem is a compilation issue, where the It would appear that i can >>>>>reference HtmlUnitTestingEngineImpl from inside the "jwebunit-commons-tests". I >>>>>then tried moving the test over to the >>>>>"jwebunit-htmlunit-plugin/net.sourceforge.jwebunit.htmlunit package" and then >>>>>ran the "mvn clean ; mvn compile ; mvn test " from there, too, but i get even >>>>>more errors. >>>>> >>>>>Any guidance would be appreciated. >>>>> >>>>>thank you. >>>>> >>>>>-Jason- >>>>> >>>>> >>>>>On Fri, Sep 3, 2010 at 3:24 PM, Jason McSwain <jas...@gm...> >>wrote: >>>>> >>>>>Hey Julien, >>>>>> >>>>>>I figured out the issue i was having with eclipse, after searching the mailing >>>>>>archives, i found a msg where you were talking about "mvn eclipse:eclipse". I >>>>>>ran that, then restarted eclipse, and all was fine. >>>>>> >>>>>>I'm currently in the process of writing the unit tests for validation. when i >>>>>>have this completed, what is the format that you would like to receive the >>>>>>changes (code + unit test class + additional html resource file) ? >>>>>> >>>>>>Thanks, >>>>>>-Jason- >>>>>> >>>>>> >>>>>> >>>>>>On Fri, Sep 3, 2010 at 12:47 PM, Jason McSwain <jas...@gm...> >>>>wrote: >>>>>> >>>>>>Hey Julien, >>>>>>> >>>>>>>i've been following the instructions on the web about setting up maven/jwebunit, >>>>>>>and i'm running into a couple problems. here is what i've done: >>>>>>> >>>>>>> >>>>>>> 1. setup ubuntu 10.04.1 64bit VM >>>>>>> 2. installed jdk 1.5.0_22 to /opt/jdk1.5.0_22 >>>>>>> 3. install svn >>>>>>> 4. check jwebunit to home dir: >>>>>>> >>>>>>> 1. svn co https://jwebunit.svn.sourceforge.net/svnroot/jwebunit jwebunit >>>>>>> 5. installed and configured maven2 >>>>>>> 6. setup env and path changes. >>>>>>> 7. defined ~/.m2/toolchains.xml >>>>>>> 1. <?xml version="1.0" encoding="UTF8"?> >>>>>>><toolchains> >>>>>>> <toolchain> >>>>>>> <type>jdk</type> >>>>>>> <provides> >>>>>>> <version>1.5</version> >>>>>>> <vendor>sun</vendor> >>>>>>> <id>1.5</id> >>>>>>> </provides> >>>>>>> <configuration> >>>>>>> <jdkHome>/opt/jdk1.5.0_22</jdkHome> >>>>>>> </configuration> >>>>>>> </toolchain> >>>>>>></toolchains> >>>>>>> 2. confirm path to java is correct >>>>>>> >>>>>>> 8. cd jwebunit/trunk >>>>>>> 9. ran mvn compile >>>>>>> >>>>>>> 10. mvn install >>>>>>> >>>>>>> 11. mvn clean >>>>>>> >>>>>>> 12. mvn test >>>>>>> >>>>>>> 13. mvn package assembly:assembly >>>>>>> 14. export MAVEN_OPTS=-Xmx384M >>>>>>> 15. mvn site >>>>>>> 16. mvn site:stage -DstagingDirectory=./staging >>>>>>> 17. all of this seems to be working fine. >>>>>>> 18. so i moved onto setting up a dev env with eclipse. >>>>>>> 1. install eclipse heilos >>>>>>> 2. install maven plugin >>>>>>> 3. import maven project into eclipse from ~/jwebunit/trunk to eclipse workspace >>>>>>>@ ~/workspace/jwebunit/trunk >>>>>>> 4. the project builds, but i have compilation errors: >>>>>>> 1. [ERROR] Cannot find matching toolchain dfinitions for the following >>>>>>>toolchain types: jdk [ vendor='sun' version='1.5' ] >>>>>>> 2. [ERROR] Build errors for jwebunit-commons-test; >>>>>>>org.apache.maven.lifecycle.LifecycleExecutionException: Failed to execute goal >>>>>>>org.apache.maven.plugins:maven-toolchains-plugin1.0:toolchain (default) on >>>>>>>project jwebunit-commons-teste: Cannot find matching toolchain definitions for >>>>>>>the following toolchain types: jdk [ vendor='sun' version='1.5' ] >>>>>>> 3. Please make sure you define the required toolchains in your >>>>>>>~/.m2/toolchains.xml file >>>>>>>I wanted to setup the eclipse env so that i could easily add the unit tests you >>>>>>>requested. I did make the change and all builds correctly, I also took the >>>>>>>"snapshot jars" and put them in my project, and it fixes the problem. I will be >>>>>>>happy to add unit tests for this, if someone can assist me in getting my eclipse >>>>>>>env working. >>>>>>> >>>>>>>here is the code i used to validate the change fixes the problem. JWebUnit >>>>>>>Trunk code change has been attached to this email. >>>>>>> >>>>>>> >>>>>>>public class TestWebTester extends WebTester { >>>>>>> private String baseUrl; >>>>>>> >>>>>>> public TestWebTester() { >>>>>>> super(); >>>>>>> init(); >>>>>>> } >>>>>>> >>>>>>> public TestWebTester(String baseUrl) { >>>>>>> super(); >>>>>>> this.baseUrl = baseUrl; >>>>>>> init(); >>>>>>> } >>>>>>> >>>>>>> public void init() { >>>>>>> System.out.println("TestWebTester.init()"); >>>>>>> // set base url >>>>>>> try { >>>>>>> ITestingEngine engine = this.getTestingEngine(); >>>>>>> HtmlUnitTestingEngineImpl impl = (HtmlUnitTestingEngineImpl) >>>>>>>engine; >>>>>>> >>>>>>> impl.setRefreshHandler(new ThreadedRefreshHandler()); >>>>>>> setBaseUrl(this.baseUrl); >>>>>>> >>>>>>> System.out.println(" -> set begin at = '/'"); >>>>>>> beginAt("/"); >>>>>>> System.out.println("-------------------------"); >>>>>>> System.out.println(impl.getPageTitle()); >>>>>>> System.out.println("-------------------------"); >>>>>>> System.out.println(impl.getPageSource()); >>>>>>> System.out.println("-------------------------"); >>>>>>> >>>>>>> } catch (TestingEngineResponseException e) { >>>>>>> throw new RuntimeException("Unexpected >>>>>>>TestingEngineResponseException during init.", e); >>>>>>> } catch (Exception e) { >>>>>>> throw new RuntimeException("Unexpected Exception during init.", >>>>>e); >>>>>>> } >>>>>>> } >>>>>>> >>>>>>> public static void main(String[] args) { >>>>>>> System.out.println("----- Begin -----"); >>>>>>> try { >>>>>>> // TestWebTester twt = new >>>>>TestWebTester("http://10.10.10.31:90/"); >>>>>>> TestWebTester twt = new >>>>TestWebTester("http://192.168.44.21:90/"); >>>>>>> >>>>>>> } catch (Throwable t) { >>>>>>> System.out.println("*** ERROR ***"); >>>>>>> t.printStackTrace(); >>>>>>> System.out.println(); >>>>>>> System.out.println("*************"); >>>>>>> } >>>>>>> >>>>>>> System.out.println("----- end -----"); >>>>>>> } >>>>>>>} >>>>>>> >>>>>>> >>>>>>> >>>>>>> >>>>>>> >>>>>>> >>>>>>>On Thu, Sep 2, 2010 at 10:05 AM, Jason McSwain <jas...@gm...> >>>>>wrote: >>>>>>> >>>>>>>Will do. I'll keep you posted when i have this completed. >>>>>>>> >>>>>>>>thanks, >>>>>>>>-Jason- >>>>>>>> >>>>>>>> >>>>>>>> >>>>>>>>On Thu, Sep 2, 2010 at 10:02 AM, Julien HENRY <he...@ya...> wrote: >>>>>>>> >>>>>>>>(I have switched to the DEV list) >>>>>>>>> >>>>>>>>>Sound good to me. Don't forget to update the WebClient if it is already >>>>>>>>>initialized: >>>>>>>>> >>>>>>>>>public void setRefreshHandler(RefreshHandler refreshHandler) { >>>>>>>>> this.refreshHanlder = refreshHandler; >>>>>>>>> //In case user wants to change RH in the middle of a test >>>>>>>>> if (wc != null) { >>>>>>>>> wc.setRefreshHandler(refreshHandler); >>>>>>>>> } >>>>>>>>>} >>>>>>>>> >>>>>>>>>Could you please try to write a small JUnit test that is failing when using >>>>>>>>>ImmediateRefreshHandler and is fixed when using your patch. I think a page with >>>>>>>>>a refresh <meta> could do the job. >>>>>>>>> >>>>>>>>>Also don't forget the ugly instanceof before casting the result of >>>>>>>>>getTestingEngine(), because JUnit tests are designed to run with all testing >>>>>>>>>engines. >>>>>>>>> >>>>>>>>>Regards, >>>>>>>>> >>>>>>>>>Julien >>>>>>>>> >>>>>>>>> >>>>>>>>> >>>>>>>>> >>>>>>>>>> >>>>>>>>>>De : Jason McSwain <jas...@gm...> >>>>>>>>>>À : Usage problems for JWebUnit <jwe...@li...> >>>>>>>>>>Envoyé le : Jeu 2 septembre 2010, 16h 43min 03s >>>>>>>>>>Objet : Re: [JWebUnit-users] Re : Re : Attempted to refresh a page using an >>>>>>>>>>ImmediateRefreshHandler which could have caused an OutOfMemoryError Please use >>>>>>>>>>WaitingRefreshHandler or ThreadedRefreshHandler instead >>>>>>>>>> >>>>>>>>>> >>>>>>>>>>i agree it's not a clean solution, but that's exactly what i was planning on >>>>>>>>>>doing. i'm working through the maven setup today and hope to have my env setup, >>>>>>>>>>compiled, and tested soon enough. >>>>>>>>>> >>>>>>>>>>here is what i was planning on doing in HtmlUnitTestingEngineImpl: >>>>>>>>>> >>>>>>>>>> >>>>>>>>>> * Add these: >>>>>>>>>> * private RefreshHandler refreshHandler = null; >>>>>>>>>> * public void setRefreshHandler(RefreshHandler refreshHandler) >>>>>>>>>> * Modify initWebClient() >>>>>>>>>> * if (this.refreshHandler == null) { >>>>>>>>>> wc.setRefreshHandler(new ImmediateRefreshHandler()); >>>>>>>>>> } else { >>>>>>>>>> wc.setRefreshHandler(this.refreshHandler); >>>>>>>>>> }i'll also be putting the updated jar in my env, to see if this fixes the >>>>>>>>>>problem. >>>>>>>>>> >>>>>>>>>>-Jason- >>>>>>>>>> >>>>>>>>>> >>>>>>>>>> >>>>>>>>>> >>>>>>>>>>On Thu, Sep 2, 2010 at 1:54 AM, Julien HENRY <he...@ya...> wrote: >>>>>>>>>> >>>>>>>>>>This is not a clean solution but an easy fix is to change visibility or add some >>>>>>>>>>methods in HtmlUnitTestingEngineImpl, and cast the use: >>>>>>>>>>>((HtmlUnitTestingEngineImpl) getTestingEngine()).xxxxx (where xxx could be >>>>>>>>>>>setDefaultRefreshHandler) before calling beginAt(). >>>>>>>>>>> >>>>>>>>>>>Regards, >>>>>>>>>>> >>>>>>>>>>>Julien >>>>>>>>>>> >>>>>>>>>>> >>>>>>>>>>>> >>>>>>>>>>>>De : Jason McSwain <jas...@gm...> >>>>>>>>>>>>À : Usage problems for JWebUnit >><jwe...@li...> >>>>>>>>>>>>Envoyé le : Mer 1 septembre 2010, 18h 34min 35s >>>>>>>>>>>>Objet : Re: [JWebUnit-users] Re : Attempted to refresh a page using an >>>>>>>>>>>>ImmediateRefreshHandler which could have caused an OutOfMemoryError Please use >>>>>>>>>>>>WaitingRefreshHandler or ThreadedRefreshHandler instead >>>>>>>>>>>> >>>>>>>>>>>> >>>>>>>>>>>>Thank you for the quick response. I would be interested in contributing. i'm >>>>>>>>>>>>looking through the contribution steps here. I would assume that it would be an >>>>>>>>>>>>easy fix. Once i have an env setup, i'll put in a fix, and let you review it. >>>>>>>>>>>> >>>>>>>>>>>>Is there any particular way that you would prefer to have this done? >>>>>>>>>>>> >>>>>>>>>>>>-Jason- >>>>>>>>>>>> >>>>>>>>>>>> >>>>>>>>>>>> >>>>>>>>>>>> >>>>>>>>>>>>On Wed, Sep 1, 2010 at 7:26 AM, Julien HENRY <he...@ya...> >wrote: >>>>>>>>>>>> >>>>>>>>>>>>Hi Jason, >>>>>>>>>>>>> >>>>>>>>>>>>>Currently there is no way to change the refresh handler. There is a long >>>>>>>>>>>>>standing issue about accessing HtmlUnit internals from JWebUnit API. At first it >>>>>>>>>>>>>was a choice to prevent user to call HtmlUnit specific API and prevent easy >>>>>>>>>>>>>switch to another testing engine but now we admit there are cases where it >>>>>>>>>>>>>should be possible. >>>>>>>>>>>>> >>>>>>>>>>>>>We are waiting for contribution in this area. >>>>>>>>>>>>> >>>>>>>>>>>>>Regards, >>>>>>>>>>>>> >>>>>>>>>>>>>Julien >>>>>>>>>>>>> >>>>>>>>>>>>> >>>>>>>>>>>>> >>>>>>>>>>>>>> >>>>>>>>>>>>>>De : Jason McSwain <jas...@gm...> >>>>>>>>>>>>>> >>>>>>>>>>>>>>À : jwe...@li... >>>>>>>>>>>>>>Envoyé le : Mer 1 septembre 2010, 1h 03min 13s >>>>>>>>>>>>>>Objet : [JWebUnit-users] Attempted to refresh a page using an >>>>>>>>>>>>>>ImmediateRefreshHandler which could have caused an OutOfMemoryError Please use >>>>>>>>>>>>>>WaitingRefreshHandler or ThreadedRefreshHandler instead >>>>>>>>>>>>>> >>>>>>>>>>>>>> >>>>>>>>>>>>>>Hello, >>>>>>>>>>>>>> >>>>>>>>>>>>>>I searched both the Development and User forums, but didn't find an answer. if >>>>>>>>>>>>>>this has already been answered please point me to the right entry in the >>>>>>>>>>>>>>archives. Thank you in advance for any help you can provide. >>>>>>>>>>>>>> >>>>>>>>>>>>>>i'm new to the list, but have been using JWebUnit for the last 6 months. it >>>>>>>>>>>>>>works great on one of the products i test, so we decided to use it on another >>>>>>>>>>>>>>product, too. This new product has a page that refreshes every 30 seconds, and >>>>>>>>>>>>>>when i go to setup my WebTester, i get an exception. about RefreshHandlers. We >>>>>>>>>>>>>>are using the HtmlUnit plugin, not selenium. The Question i have is how do i >>>>>>>>>>>>>>change the Refresh handler? This error happens when i call >>>>>>>>>>>>>>WebTester.beginAt("/"), and that method initializes the WebClient inside a >>>>>>>>>>>>>>private method, and sets the refreshHandler to the ImmediateRefreshHandler. i'd >>>>>>>>>>>>>>like to use another type. >>>>>>>>>>>>>> >>>>>>>>>>>>>> >>>>>>>>>>>>>>Error: >>>>>>>>>>>>>>java.lang.RuntimeException: Unexpected Exception during init. >>>>>>>>>>>>>> at TestWebTester.init(TestWebTester.java:53) >>>>>>>>>>>>>> at TestWebTester.<init>(TestWebTester.java:37) >>>>>>>>>>>>>> at TestWebTester.main(TestWebTester.java:60) >>>>>>>>>>>>>>Caused by: java.lang.RuntimeException: Refresh to http://10.10.10.31:90/ (30s) >>>>>>>>>>>>>>aborted by HtmlUnit: Attempted to refresh a page using an >>>>>>>>>>>>>>ImmediateRefreshHandler which could have caused an OutOfMemoryError Please use >>>>>>>>>>>>>>WaitingRefreshHandler or ThreadedRefreshHandler instead. >>>>>>>>>>>>>> at >>>>>>>>>>>>>>com.gargoylesoftware.htmlunit.ImmediateRefreshHandler.handleRefresh(ImmediateRefreshHandler.java:58) >>>>>>>>>>>>>> >>>>>>>>>>>>>> at >>>>>>>>>>>>>>com.gargoylesoftware.htmlunit.html.HtmlPage.executeRefreshIfNeeded(HtmlPage.java:1279) >>>>>>>>>>>>>> >>>>>>>>>>>>>> at >>>>>>>>>>>>>com.gargoylesoftware.htmlunit.html.HtmlPage.initialize(HtmlPage.java:218) >>>>>>>>>>>>>> at >>>>>>>>>>>>>>com.gargoylesoftware.htmlunit.WebClient.loadWebResponseInto(WebClient.java:427) >>>>>>>>>>>>>> at >>>>>>>com.gargoylesoftware.htmlunit.WebClient.getPage(WebClient.java:303) >>>>>>>>>>>>>> at >>>>>>>com.gargoylesoftware.htmlunit.WebClient.getPage(WebClient.java:360) >>>>>>>>>>>>>> at >>>>>>>>>>>>>>net.sourceforge.jwebunit.htmlunit.HtmlUnitTestingEngineImpl.gotoPage(HtmlUnitTestingEngineImpl.java:248) >>>>>>>>>>>>>> >>>>>>>>>>>>>> at >>>>>>>>>>>>>>net.sourceforge.jwebunit.htmlunit.HtmlUnitTestingEngineImpl.beginAt(HtmlUnitTestingEngineImpl.java:207) >>>>>>>>>>>>>> >>>>>>>>>>>>>> at >>>>>>>>net.sourceforge.jwebunit.junit.WebTester.beginAt(WebTester.java:228) >>>>>>>>>>>>>> at TestWebTester.init(TestWebTester.java:48) >>>>>>>>>>>>>> >>>>>>>>>>>>>> >>>>>>>>>>>>>>Here is an example code snippet that uncovers the issue: >>>>>>>>>>>>>> >>>>>>>>>>>>>>**************************************************************************************** >>>>>>>>>>>>>> >>>>>>>>>>>>>>public class TestWebTester extends WebTester { >>>>>>>>>>>>>> private String baseUrl; >>>>>>>>>>>>>> >>>>>>>>>>>>>> public TestWebTester() { >>>>>>>>>>>>>> super(); >>>>>>>>>>>>>> init(); >>>>>>>>>>>>>> } >>>>>>>>>>>>>> >>>>>>>>>>>>>> public TestWebTester(String baseUrl) { >>>>>>>>>>>>>> super(); >>>>>>>>>>>>>> this.baseUrl = baseUrl; >>>>>>>>>>>>>> init(); >>>>>>>>>>>>>> } >>>>>>>>>>>>>> >>>>>>>>>>>>>> public void init() { >>>>>>>>>>>>>> System.out.println("TestWebTester.init()"); >>>>>>>>>>>>>> // set base url >>>>>>>>>>>>>> try { >>>>>>>>>>>>>> >>>>>>>>>>>>>> setBaseUrl(this.baseUrl); >>>>>>>>>>>>>> // first part to load >>>>>>>>>>>>>> System.out.println(" -> set begin at = '/'"); >>>>>>>>>>>>>> beginAt("/"); >>>>>>>>>>>>>> >>>>>>>>>>>>>> } catch (TestingEngineResponseException e) { >>>>>>>>>>>>>> throw new RuntimeException("Unexpected >>>>>>>>>>>>>>TestingEngineResponseException during init.", e); >>>>>>>>>>>>>> } catch (Exception e) { >>>>>>>>>>>>>> throw new RuntimeException("Unexpected Exception during init.", >>>>>>>>>>>>e); >>>>>>>>>>>>>> } >>>>>>>>>>>>>> } >>>>>>>>>>>>>> >>>>>>>>>>>>>> public static void main(String[] args) { >>>>>>>>>>>>>> System.out.println("----- Begin -----"); >>>>>>>>>>>>>> try { >>>>>>>>>>>>>> TestWebTester twt = new >>>>>>>>>TestWebTester("http://10.10.10.31:90/"); >>>>>>>>>>>>>> } catch (Throwable t) { >>>>>>>>>>>>>> System.out.println("*** ERROR ***"); >>>>>>>>>>>>>> t.printStackTrace(); >>>>>>>>>>>>>> System.out.println(); >>>>>>>>>>>>>> System.out.println("*************"); >>>>>>>>>>>>>> } >>>>>>>>>>>>>> >>>>>>>>>>>>>> System.out.println("----- end -----"); >>>>>>>>>>>>>> } >>>>>>>>>>>>>>} >>>>>>>>>>>>>>**************************************************************************************** >>>>>>>>>>>>>> >>>>>>>>>>>>>> >>>>>>>>>>>>>> >>>>>>>>>>>>>> >>>>>>>>>>>>>> >>>>>>>>>>>>>> >>>>>>>>>>>>>> >>>>>>>>>>>>> >>>>>>>>>>>>>------------------------------------------------------------------------------ >>>>>>>>>> >>>>>>>>>>>>>This SF.net Dev2Dev email is sponsored by: >>>>>>>>>>>>> >>>>>>>>>>>>>Show off your parallel programming skills. >>>>>>>>>>>>>Enter the Intel(R) Threading Challenge 2010. >>>>>>>>>>>>>http://p.sf.net/sfu/intel-thread-sfd >>>>>>>>>>>>>_______________________________________________ >>>>>>>>>>>>>JWebUnit-users mailing list >>>>>>>>>>>>>JWe...@li... >>>>>>>>>>>>>https://lists.sourceforge.net/lists/listinfo/jwebunit-users >>>>>>>>>>>>> >>>>>>>>>>>>> >>>>>>>>>>>> >>>>>>>>>>> >>>>>>>>>>>------------------------------------------------------------------------------ >>>>>>>> >>>>>>>>>>>This SF.net Dev2Dev email is sponsored by: >>>>>>>>>>> >>>>>>>>>>>Show off your parallel programming skills. >>>>>>>>>>>Enter the Intel(R) Threading Challenge 2010. >>>>>>>>>>>http://p.sf.net/sfu/intel-thread-sfd >>>>>>>>>>>_______________________________________________ >>>>>>>>>>>JWebUnit-users mailing list >>>>>>>>>>>JWe...@li... >>>>>>>>>>>https://lists.sourceforge.net/lists/listinfo/jwebunit-users >>>>>>>>>>> >>>>>>>>>>> >>>>>>>>>> >>>>>>>>> >>>>>>>> >>>>>>> >>>>>> >>>>> >>>> >>> >> > |
|
From: <he...@us...> - 2010-09-14 12:09:07
|
Revision: 844
http://jwebunit.svn.sourceforge.net/jwebunit/?rev=844&view=rev
Author: henryju
Date: 2010-09-14 12:08:58 +0000 (Tue, 14 Sep 2010)
Log Message:
-----------
[1864365] Allow to change HtmlUnit refresh handler. Thanks to Jason McSwain for the patch.
Modified Paths:
--------------
trunk/jwebunit-htmlunit-plugin/src/main/java/net/sourceforge/jwebunit/htmlunit/HtmlUnitTestingEngineImpl.java
trunk/src/changes/changes.xml
trunk/src/site/fml/faq.fml
Added Paths:
-----------
trunk/jwebunit-commons-tests/src/main/resources/testcases/RefreshHandlerTest/
trunk/jwebunit-commons-tests/src/main/resources/testcases/RefreshHandlerTest/testPage.html
trunk/jwebunit-htmlunit-plugin/src/test/java/net/sourceforge/jwebunit/htmlunit/RefreshHandlerTest.java
Added: trunk/jwebunit-commons-tests/src/main/resources/testcases/RefreshHandlerTest/testPage.html
===================================================================
--- trunk/jwebunit-commons-tests/src/main/resources/testcases/RefreshHandlerTest/testPage.html (rev 0)
+++ trunk/jwebunit-commons-tests/src/main/resources/testcases/RefreshHandlerTest/testPage.html 2010-09-14 12:08:58 UTC (rev 844)
@@ -0,0 +1,43 @@
+<!--
+
+ Copyright (c) 2010, JWebUnit team.
+
+ This file is part of JWebUnit.
+
+ JWebUnit is free software: you can redistribute it and/or modify
+ it under the terms of the GNU Lesser General Public License as published by
+ the Free Software Foundation, either version 3 of the License, or
+ (at your option) any later version.
+
+ JWebUnit is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public License
+ along with JWebUnit. If not, see <http://www.gnu.org/licenses/>.
+
+-->
+
+<html>
+ <head>
+ <meta http-equiv="refresh" content="5">
+ <title>RefreshHandler - Test Page</title>
+ </head>
+ <body>
+ <p>Hello World</p>
+ <table>
+ <tr>
+ <td>
+ The Current Time is:
+ </td>
+ <td>
+ <script type="text/javascript">
+ var currentTime = new Date()
+ document.write(currentTime);
+ </script>
+ </td>
+ </tr>
+ </table>
+ </body>
+</html>
Modified: trunk/jwebunit-htmlunit-plugin/src/main/java/net/sourceforge/jwebunit/htmlunit/HtmlUnitTestingEngineImpl.java
===================================================================
--- trunk/jwebunit-htmlunit-plugin/src/main/java/net/sourceforge/jwebunit/htmlunit/HtmlUnitTestingEngineImpl.java 2010-07-04 16:01:51 UTC (rev 843)
+++ trunk/jwebunit-htmlunit-plugin/src/main/java/net/sourceforge/jwebunit/htmlunit/HtmlUnitTestingEngineImpl.java 2010-09-14 12:08:58 UTC (rev 844)
@@ -68,6 +68,7 @@
import com.gargoylesoftware.htmlunit.JavaScriptPage;
import com.gargoylesoftware.htmlunit.Page;
import com.gargoylesoftware.htmlunit.PromptHandler;
+import com.gargoylesoftware.htmlunit.RefreshHandler;
import com.gargoylesoftware.htmlunit.TextPage;
import com.gargoylesoftware.htmlunit.UnexpectedPage;
import com.gargoylesoftware.htmlunit.WebClient;
@@ -117,6 +118,10 @@
private final Logger logger = LoggerFactory.getLogger(HtmlUnitTestingEngineImpl.class);
/**
+ * holder for alternative refresh handler.
+ */
+ private RefreshHandler refreshHandler;
+ /**
* Encapsulate browser abilities.
*/
private WebClient wc;
@@ -252,7 +257,7 @@
// only throw exception if necessary
if (!ignoreFailingStatusCodes) {
throw new TestingEngineResponseException(
- ex.getStatusCode(), ex);
+ "unexpected status code ["+ex.getStatusCode()+"] at URL: ["+initialURL+"]", ex);
}
} catch (IOException ex) {
throw new RuntimeException(ex);
@@ -806,7 +811,11 @@
wc.setJavaScriptEnabled(jsEnabled);
wc.setThrowExceptionOnScriptError(throwExceptionOnScriptError);
wc.setRedirectEnabled(true);
- wc.setRefreshHandler(new ImmediateRefreshHandler());
+ if (refreshHandler == null){
+ wc.setRefreshHandler(new ImmediateRefreshHandler());
+ } else {
+ wc.setRefreshHandler(refreshHandler);
+ }
wc.setTimeout(timeout);
DefaultCredentialsProvider creds = new DefaultCredentialsProvider();
if (getTestContext().hasAuthorization()) {
@@ -2321,4 +2330,13 @@
timeout = milliseconds;
}
+
+ public void setRefreshHandler(RefreshHandler handler){
+ this.refreshHandler = handler;
+
+ if (wc != null){
+ wc.setRefreshHandler(refreshHandler);
+ }
+ }
+
}
Added: trunk/jwebunit-htmlunit-plugin/src/test/java/net/sourceforge/jwebunit/htmlunit/RefreshHandlerTest.java
===================================================================
--- trunk/jwebunit-htmlunit-plugin/src/test/java/net/sourceforge/jwebunit/htmlunit/RefreshHandlerTest.java (rev 0)
+++ trunk/jwebunit-htmlunit-plugin/src/test/java/net/sourceforge/jwebunit/htmlunit/RefreshHandlerTest.java 2010-09-14 12:08:58 UTC (rev 844)
@@ -0,0 +1,126 @@
+/**
+ * Copyright (c) 2010, JWebUnit team.
+ *
+ * This file is part of JWebUnit.
+ *
+ * JWebUnit is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU Lesser General Public License as published by
+ * the Free Software Foundation, either version 3 of the License, or
+ * (at your option) any later version.
+ *
+ * JWebUnit is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public License
+ * along with JWebUnit. If not, see <http://www.gnu.org/licenses/>.
+ */
+
+package net.sourceforge.jwebunit.htmlunit;
+
+import junit.framework.Assert;
+import junit.framework.AssertionFailedError;
+import junit.framework.Test;
+import junit.framework.TestSuite;
+import net.sourceforge.jwebunit.tests.JWebUnitAPITestCase;
+import net.sourceforge.jwebunit.tests.util.JettySetup;
+import net.sourceforge.jwebunit.htmlunit.HtmlUnitTestingEngineImpl;
+import com.gargoylesoftware.htmlunit.ThreadedRefreshHandler;
+import com.gargoylesoftware.htmlunit.WaitingRefreshHandler;
+
+/**
+ * Unit test to validate JWEbUnit's HtmlUnit plugin will now allow for custom
+ * RefreshHandler to be passed in prior to initialization, as well as changed on
+ * the fly.
+ *
+ * @Date 09/03/2010
+ * @author Jason McSwain
+ */
+public class RefreshHandlerTest extends JWebUnitAPITestCase {
+ public RefreshHandlerTest(String name) {
+ super(name);
+ }
+
+ public static Test suite() {
+ return new JettySetup(new TestSuite(RefreshHandlerTest.class));
+ }
+
+ public void setUp() throws Exception {
+ super.setUp();
+ }
+
+ public void tearDown() throws Exception {
+ super.tearDown();
+ }
+
+ public void testDefaultRefreshHandler() throws Exception {
+ if (this.getTestingEngine() instanceof HtmlUnitTestingEngineImpl) {
+ setBaseUrl(HOST_PATH + "/RefreshHandlerTest");
+ getTestContext().setResourceBundleName("RefreshHandlerTest");
+ try {
+ beginAt("/testPage.html");
+ fail("expected exception b/c page refreshes, but received no exception");
+ } catch (RuntimeException re) {
+ String msg = re.getMessage();
+ assertTrue(
+ "msg was not as expected.\n[" + msg + "]",
+ msg.endsWith("aborted by HtmlUnit: Attempted to refresh a page using an ImmediateRefreshHandler which could have caused an OutOfMemoryError Please use WaitingRefreshHandler or ThreadedRefreshHandler instead."));
+ } catch (Exception e) {
+ throw new Exception("received unexpected Exception.", e);
+ }
+ } else {
+ System.out
+ .println("[WARN] skipping test [testDefaultRefreshHandler] b/c it only applies to HtmlUnitTestEngineImpl");
+ }
+ }
+
+ public void testAlternateRefreshHandler() throws Exception {
+ if (this.getTestingEngine() instanceof HtmlUnitTestingEngineImpl) {
+ HtmlUnitTestingEngineImpl engine = (HtmlUnitTestingEngineImpl) this
+ .getTestingEngine();
+ setBaseUrl(HOST_PATH + "/RefreshHandlerTest");
+ getTestContext().setResourceBundleName("RefreshHandlerTest");
+
+ engine.setRefreshHandler(new ThreadedRefreshHandler());
+ beginAt("/testPage.html");
+
+ assertTrue("refresh handler was not of expected type.["
+ + engine.getWebClient().getRefreshHandler().getClass()
+ .getName() + "]", engine.getWebClient()
+ .getRefreshHandler() instanceof ThreadedRefreshHandler);
+
+ } else {
+ System.out
+ .println("[WARN] skipping test [testAlternateRefreshHandler] b/c it only applies to HtmlUnitTestEngineImpl");
+ }
+ }
+
+ public void testChangeRefreshHandler() throws Exception {
+ if (this.getTestingEngine() instanceof HtmlUnitTestingEngineImpl) {
+ HtmlUnitTestingEngineImpl engine = (HtmlUnitTestingEngineImpl) this
+ .getTestingEngine();
+ setBaseUrl(HOST_PATH + "/RefreshHandlerTest");
+ getTestContext().setResourceBundleName("RefreshHandlerTest");
+
+ engine.setRefreshHandler(new ThreadedRefreshHandler());
+ beginAt("/testPage.html");
+
+ assertTrue("refresh handler was not of expected type.["
+ + engine.getWebClient().getRefreshHandler().getClass()
+ .getName() + "]", engine.getWebClient()
+ .getRefreshHandler() instanceof ThreadedRefreshHandler);
+
+ engine.setRefreshHandler(new WaitingRefreshHandler());
+ assertTrue("refresh handler was not of expected type.["
+ + engine.getWebClient().getRefreshHandler().getClass()
+ .getName() + "]", engine.getWebClient()
+ .getRefreshHandler() instanceof WaitingRefreshHandler);
+
+ } else {
+ System.out
+ .println("[WARN] skipping test [testChangeRefreshHandler] b/c it only applies to HtmlUnitTestEngineImpl");
+ }
+ }
+
+}
Modified: trunk/src/changes/changes.xml
===================================================================
--- trunk/src/changes/changes.xml 2010-07-04 16:01:51 UTC (rev 843)
+++ trunk/src/changes/changes.xml 2010-09-14 12:08:58 UTC (rev 844)
@@ -28,6 +28,11 @@
</author>
</properties>
<body>
+ <release version="2.5" date="UNKNOW" description="">
+ <action type="add" dev="henryju" issue="1864365" due-to="Jason McSwain">
+ Added the ability to change RefreshHandler in HtmlUnitTestingEngine.
+ </action>
+ </release>
<release version="2.4" date="July 4, 2010" description="Licensing change">
<action type="update" dev="henryju">
License was changed to LGPL v3
Modified: trunk/src/site/fml/faq.fml
===================================================================
--- trunk/src/site/fml/faq.fml 2010-07-04 16:01:51 UTC (rev 843)
+++ trunk/src/site/fml/faq.fml 2010-09-14 12:08:58 UTC (rev 844)
@@ -73,4 +73,20 @@
</faq>
</part>
+ <part id="HtmlUnit">
+ <title>HtmlUnit testing engine</title>
+
+ <faq id="htmlunit-change-refreshhandler">
+ <question>
+ How can I change HtmlUnit refresh handler (default is ImmediateRefreshHandler)?
+ </question>
+ <answer>
+ <p>Warning: this is not something easily portable to other testing engine.</p>
+ <source>if (getTestingEngine() instanceof HtmlUnitTestingEngineImpl) {
+ HtmlUnitTestingEngineImpl engine = (HtmlUnitTestingEngineImpl) getTestingEngine();
+ engine.setRefreshHandler(new ThreadedRefreshHandler());
+}</source>
+ </answer>
+ </faq>
+ </part>
</faqs>
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: Julien H. <he...@ya...> - 2010-09-05 16:45:22
|
Hi Jason, > what is the format that you would like to receive the changes (code + unit test >class + additional html resource file) A standard .patch file would be great (you can create one using svn patch command). > where the It would appear that i can reference HtmlUnitTestingEngineImpl from >inside the "jwebunit-commons-tests". You are right, there is a dependency issue because common-tests are designed to be independent of the testing engine. So this is the testing engine module that depends on common-tests. I will look at your work but I guess the best solution is to put this test that is very specific to HtmlUnit in HtmlUnit module. Regards, Julien > >De : Jason McSwain <jas...@gm...> >À : Julien HENRY <he...@ya...> >Envoyé le : Sam 4 septembre 2010, 0h 24min 20s >Objet : Re: Re : Attempted to refresh a page using an ImmediateRefreshHandler >which could have caused an OutOfMemoryError Please use WaitingRefreshHandler or >ThreadedRefreshHandler instead > >Ok, next question: > >If i wanted to create a Test Class "RefreshHandlerTest" and an associated >resource, > > >I tried putting the test in the >"jwebunit-common-tests/src/test/java/net.sourceforge.jwebunit.tests.util.reflect" > >and i put the test html page into >"jwebunit-common-tests/src/main/resources/testcases/RefreshHandlerTest/testPage.html" > > >ive attached them, incase you want to give it a try yourself. > >My problem is a compilation issue, where the It would appear that i can >reference HtmlUnitTestingEngineImpl from inside the "jwebunit-commons-tests". I >then tried moving the test over to the >"jwebunit-htmlunit-plugin/net.sourceforge.jwebunit.htmlunit package" and then >ran the "mvn clean ; mvn compile ; mvn test " from there, too, but i get even >more errors. > >Any guidance would be appreciated. > >thank you. > >-Jason- > > >On Fri, Sep 3, 2010 at 3:24 PM, Jason McSwain <jas...@gm...> wrote: > >Hey Julien, >> >>I figured out the issue i was having with eclipse, after searching the mailing >>archives, i found a msg where you were talking about "mvn eclipse:eclipse". I >>ran that, then restarted eclipse, and all was fine. >> >>I'm currently in the process of writing the unit tests for validation. when i >>have this completed, what is the format that you would like to receive the >>changes (code + unit test class + additional html resource file) ? >> >>Thanks, >>-Jason- >> >> >> >>On Fri, Sep 3, 2010 at 12:47 PM, Jason McSwain <jas...@gm...> wrote: >> >>Hey Julien, >>> >>>i've been following the instructions on the web about setting up maven/jwebunit, >>>and i'm running into a couple problems. here is what i've done: >>> >>> >>> 1. setup ubuntu 10.04.1 64bit VM >>> 2. installed jdk 1.5.0_22 to /opt/jdk1.5.0_22 >>> 3. install svn >>> 4. check jwebunit to home dir: >>> >>> 1. svn co https://jwebunit.svn.sourceforge.net/svnroot/jwebunit jwebunit >>> 5. installed and configured maven2 >>> 6. setup env and path changes. >>> 7. defined ~/.m2/toolchains.xml >>> 1. <?xml version="1.0" encoding="UTF8"?> >>><toolchains> >>> <toolchain> >>> <type>jdk</type> >>> <provides> >>> <version>1.5</version> >>> <vendor>sun</vendor> >>> <id>1.5</id> >>> </provides> >>> <configuration> >>> <jdkHome>/opt/jdk1.5.0_22</jdkHome> >>> </configuration> >>> </toolchain> >>></toolchains> >>> 2. confirm path to java is correct >>> >>> 8. cd jwebunit/trunk >>> 9. ran mvn compile >>> >>> 10. mvn install >>> >>> 11. mvn clean >>> >>> 12. mvn test >>> >>> 13. mvn package assembly:assembly >>> 14. export MAVEN_OPTS=-Xmx384M >>> 15. mvn site >>> 16. mvn site:stage -DstagingDirectory=./staging >>> 17. all of this seems to be working fine. >>> 18. so i moved onto setting up a dev env with eclipse. >>> 1. install eclipse heilos >>> 2. install maven plugin >>> 3. import maven project into eclipse from ~/jwebunit/trunk to eclipse workspace >>>@ ~/workspace/jwebunit/trunk >>> 4. the project builds, but i have compilation errors: >>> 1. [ERROR] Cannot find matching toolchain dfinitions for the following >>>toolchain types: jdk [ vendor='sun' version='1.5' ] >>> 2. [ERROR] Build errors for jwebunit-commons-test; >>>org.apache.maven.lifecycle.LifecycleExecutionException: Failed to execute goal >>>org.apache.maven.plugins:maven-toolchains-plugin1.0:toolchain (default) on >>>project jwebunit-commons-teste: Cannot find matching toolchain definitions for >>>the following toolchain types: jdk [ vendor='sun' version='1.5' ] >>> 3. Please make sure you define the required toolchains in your >>>~/.m2/toolchains.xml file >>>I wanted to setup the eclipse env so that i could easily add the unit tests you >>>requested. I did make the change and all builds correctly, I also took the >>>"snapshot jars" and put them in my project, and it fixes the problem. I will be >>>happy to add unit tests for this, if someone can assist me in getting my eclipse >>>env working. >>> >>>here is the code i used to validate the change fixes the problem. JWebUnit >>>Trunk code change has been attached to this email. >>> >>> >>>public class TestWebTester extends WebTester { >>> private String baseUrl; >>> >>> public TestWebTester() { >>> super(); >>> init(); >>> } >>> >>> public TestWebTester(String baseUrl) { >>> super(); >>> this.baseUrl = baseUrl; >>> init(); >>> } >>> >>> public void init() { >>> System.out.println("TestWebTester.init()"); >>> // set base url >>> try { >>> ITestingEngine engine = this.getTestingEngine(); >>> HtmlUnitTestingEngineImpl impl = (HtmlUnitTestingEngineImpl) >>>engine; >>> >>> impl.setRefreshHandler(new ThreadedRefreshHandler()); >>> setBaseUrl(this.baseUrl); >>> >>> System.out.println(" -> set begin at = '/'"); >>> beginAt("/"); >>> System.out.println("-------------------------"); >>> System.out.println(impl.getPageTitle()); >>> System.out.println("-------------------------"); >>> System.out.println(impl.getPageSource()); >>> System.out.println("-------------------------"); >>> >>> } catch (TestingEngineResponseException e) { >>> throw new RuntimeException("Unexpected >>>TestingEngineResponseException during init.", e); >>> } catch (Exception e) { >>> throw new RuntimeException("Unexpected Exception during init.", >e); >>> } >>> } >>> >>> public static void main(String[] args) { >>> System.out.println("----- Begin -----"); >>> try { >>> // TestWebTester twt = new >TestWebTester("http://10.10.10.31:90/"); >>> TestWebTester twt = new TestWebTester("http://192.168.44.21:90/"); >>> >>> } catch (Throwable t) { >>> System.out.println("*** ERROR ***"); >>> t.printStackTrace(); >>> System.out.println(); >>> System.out.println("*************"); >>> } >>> >>> System.out.println("----- end -----"); >>> } >>>} >>> >>> >>> >>> >>> >>> >>>On Thu, Sep 2, 2010 at 10:05 AM, Jason McSwain <jas...@gm...> >wrote: >>> >>>Will do. I'll keep you posted when i have this completed. >>>> >>>>thanks, >>>>-Jason- >>>> >>>> >>>> >>>>On Thu, Sep 2, 2010 at 10:02 AM, Julien HENRY <he...@ya...> wrote: >>>> >>>>(I have switched to the DEV list) >>>>> >>>>>Sound good to me. Don't forget to update the WebClient if it is already >>>>>initialized: >>>>> >>>>>public void setRefreshHandler(RefreshHandler refreshHandler) { >>>>> this.refreshHanlder = refreshHandler; >>>>> //In case user wants to change RH in the middle of a test >>>>> if (wc != null) { >>>>> wc.setRefreshHandler(refreshHandler); >>>>> } >>>>>} >>>>> >>>>>Could you please try to write a small JUnit test that is failing when using >>>>>ImmediateRefreshHandler and is fixed when using your patch. I think a page with >>>>>a refresh <meta> could do the job. >>>>> >>>>>Also don't forget the ugly instanceof before casting the result of >>>>>getTestingEngine(), because JUnit tests are designed to run with all testing >>>>>engines. >>>>> >>>>>Regards, >>>>> >>>>>Julien >>>>> >>>>> >>>>> >>>>> >>>>>> >>>>>>De : Jason McSwain <jas...@gm...> >>>>>>À : Usage problems for JWebUnit <jwe...@li...> >>>>>>Envoyé le : Jeu 2 septembre 2010, 16h 43min 03s >>>>>>Objet : Re: [JWebUnit-users] Re : Re : Attempted to refresh a page using an >>>>>>ImmediateRefreshHandler which could have caused an OutOfMemoryError Please use >>>>>>WaitingRefreshHandler or ThreadedRefreshHandler instead >>>>>> >>>>>> >>>>>>i agree it's not a clean solution, but that's exactly what i was planning on >>>>>>doing. i'm working through the maven setup today and hope to have my env setup, >>>>>>compiled, and tested soon enough. >>>>>> >>>>>>here is what i was planning on doing in HtmlUnitTestingEngineImpl: >>>>>> >>>>>> >>>>>> * Add these: >>>>>> * private RefreshHandler refreshHandler = null; >>>>>> * public void setRefreshHandler(RefreshHandler refreshHandler) >>>>>> * Modify initWebClient() >>>>>> * if (this.refreshHandler == null) { >>>>>> wc.setRefreshHandler(new ImmediateRefreshHandler()); >>>>>> } else { >>>>>> wc.setRefreshHandler(this.refreshHandler); >>>>>> }i'll also be putting the updated jar in my env, to see if this fixes the >>>>>>problem. >>>>>> >>>>>>-Jason- >>>>>> >>>>>> >>>>>> >>>>>> >>>>>>On Thu, Sep 2, 2010 at 1:54 AM, Julien HENRY <he...@ya...> wrote: >>>>>> >>>>>>This is not a clean solution but an easy fix is to change visibility or add some >>>>>>methods in HtmlUnitTestingEngineImpl, and cast the use: >>>>>>>((HtmlUnitTestingEngineImpl) getTestingEngine()).xxxxx (where xxx could be >>>>>>>setDefaultRefreshHandler) before calling beginAt(). >>>>>>> >>>>>>>Regards, >>>>>>> >>>>>>>Julien >>>>>>> >>>>>>> >>>>>>>> >>>>>>>>De : Jason McSwain <jas...@gm...> >>>>>>>>À : Usage problems for JWebUnit <jwe...@li...> >>>>>>>>Envoyé le : Mer 1 septembre 2010, 18h 34min 35s >>>>>>>>Objet : Re: [JWebUnit-users] Re : Attempted to refresh a page using an >>>>>>>>ImmediateRefreshHandler which could have caused an OutOfMemoryError Please use >>>>>>>>WaitingRefreshHandler or ThreadedRefreshHandler instead >>>>>>>> >>>>>>>> >>>>>>>>Thank you for the quick response. I would be interested in contributing. i'm >>>>>>>>looking through the contribution steps here. I would assume that it would be an >>>>>>>>easy fix. Once i have an env setup, i'll put in a fix, and let you review it. >>>>>>>> >>>>>>>>Is there any particular way that you would prefer to have this done? >>>>>>>> >>>>>>>>-Jason- >>>>>>>> >>>>>>>> >>>>>>>> >>>>>>>> >>>>>>>>On Wed, Sep 1, 2010 at 7:26 AM, Julien HENRY <he...@ya...> wrote: >>>>>>>> >>>>>>>>Hi Jason, >>>>>>>>> >>>>>>>>>Currently there is no way to change the refresh handler. There is a long >>>>>>>>>standing issue about accessing HtmlUnit internals from JWebUnit API. At first it >>>>>>>>>was a choice to prevent user to call HtmlUnit specific API and prevent easy >>>>>>>>>switch to another testing engine but now we admit there are cases where it >>>>>>>>>should be possible. >>>>>>>>> >>>>>>>>>We are waiting for contribution in this area. >>>>>>>>> >>>>>>>>>Regards, >>>>>>>>> >>>>>>>>>Julien >>>>>>>>> >>>>>>>>> >>>>>>>>> >>>>>>>>>> >>>>>>>>>>De : Jason McSwain <jas...@gm...> >>>>>>>>>> >>>>>>>>>>À : jwe...@li... >>>>>>>>>>Envoyé le : Mer 1 septembre 2010, 1h 03min 13s >>>>>>>>>>Objet : [JWebUnit-users] Attempted to refresh a page using an >>>>>>>>>>ImmediateRefreshHandler which could have caused an OutOfMemoryError Please use >>>>>>>>>>WaitingRefreshHandler or ThreadedRefreshHandler instead >>>>>>>>>> >>>>>>>>>> >>>>>>>>>>Hello, >>>>>>>>>> >>>>>>>>>>I searched both the Development and User forums, but didn't find an answer. if >>>>>>>>>>this has already been answered please point me to the right entry in the >>>>>>>>>>archives. Thank you in advance for any help you can provide. >>>>>>>>>> >>>>>>>>>>i'm new to the list, but have been using JWebUnit for the last 6 months. it >>>>>>>>>>works great on one of the products i test, so we decided to use it on another >>>>>>>>>>product, too. This new product has a page that refreshes every 30 seconds, and >>>>>>>>>>when i go to setup my WebTester, i get an exception. about RefreshHandlers. We >>>>>>>>>>are using the HtmlUnit plugin, not selenium. The Question i have is how do i >>>>>>>>>>change the Refresh handler? This error happens when i call >>>>>>>>>>WebTester.beginAt("/"), and that method initializes the WebClient inside a >>>>>>>>>>private method, and sets the refreshHandler to the ImmediateRefreshHandler. i'd >>>>>>>>>>like to use another type. >>>>>>>>>> >>>>>>>>>> >>>>>>>>>>Error: >>>>>>>>>>java.lang.RuntimeException: Unexpected Exception during init. >>>>>>>>>> at TestWebTester.init(TestWebTester.java:53) >>>>>>>>>> at TestWebTester.<init>(TestWebTester.java:37) >>>>>>>>>> at TestWebTester.main(TestWebTester.java:60) >>>>>>>>>>Caused by: java.lang.RuntimeException: Refresh to http://10.10.10.31:90/ (30s) >>>>>>>>>>aborted by HtmlUnit: Attempted to refresh a page using an >>>>>>>>>>ImmediateRefreshHandler which could have caused an OutOfMemoryError Please use >>>>>>>>>>WaitingRefreshHandler or ThreadedRefreshHandler instead. >>>>>>>>>> at >>>>>>>>>>com.gargoylesoftware.htmlunit.ImmediateRefreshHandler.handleRefresh(ImmediateRefreshHandler.java:58) >>>>>>>>>> >>>>>>>>>> at >>>>>>>>>>com.gargoylesoftware.htmlunit.html.HtmlPage.executeRefreshIfNeeded(HtmlPage.java:1279) >>>>>>>>>> >>>>>>>>>> at >>>>>>>>>com.gargoylesoftware.htmlunit.html.HtmlPage.initialize(HtmlPage.java:218) >>>>>>>>>> at >>>>>>>>>>com.gargoylesoftware.htmlunit.WebClient.loadWebResponseInto(WebClient.java:427) >>>>>>>>>> at >>>com.gargoylesoftware.htmlunit.WebClient.getPage(WebClient.java:303) >>>>>>>>>> at >>>com.gargoylesoftware.htmlunit.WebClient.getPage(WebClient.java:360) >>>>>>>>>> at >>>>>>>>>>net.sourceforge.jwebunit.htmlunit.HtmlUnitTestingEngineImpl.gotoPage(HtmlUnitTestingEngineImpl.java:248) >>>>>>>>>> >>>>>>>>>> at >>>>>>>>>>net.sourceforge.jwebunit.htmlunit.HtmlUnitTestingEngineImpl.beginAt(HtmlUnitTestingEngineImpl.java:207) >>>>>>>>>> >>>>>>>>>> at >>>>net.sourceforge.jwebunit.junit.WebTester.beginAt(WebTester.java:228) >>>>>>>>>> at TestWebTester.init(TestWebTester.java:48) >>>>>>>>>> >>>>>>>>>> >>>>>>>>>>Here is an example code snippet that uncovers the issue: >>>>>>>>>> >>>>>>>>>>**************************************************************************************** >>>>>>>>>> >>>>>>>>>>public class TestWebTester extends WebTester { >>>>>>>>>> private String baseUrl; >>>>>>>>>> >>>>>>>>>> public TestWebTester() { >>>>>>>>>> super(); >>>>>>>>>> init(); >>>>>>>>>> } >>>>>>>>>> >>>>>>>>>> public TestWebTester(String baseUrl) { >>>>>>>>>> super(); >>>>>>>>>> this.baseUrl = baseUrl; >>>>>>>>>> init(); >>>>>>>>>> } >>>>>>>>>> >>>>>>>>>> public void init() { >>>>>>>>>> System.out.println("TestWebTester.init()"); >>>>>>>>>> // set base url >>>>>>>>>> try { >>>>>>>>>> >>>>>>>>>> setBaseUrl(this.baseUrl); >>>>>>>>>> // first part to load >>>>>>>>>> System.out.println(" -> set begin at = '/'"); >>>>>>>>>> beginAt("/"); >>>>>>>>>> >>>>>>>>>> } catch (TestingEngineResponseException e) { >>>>>>>>>> throw new RuntimeException("Unexpected >>>>>>>>>>TestingEngineResponseException during init.", e); >>>>>>>>>> } catch (Exception e) { >>>>>>>>>> throw new RuntimeException("Unexpected Exception during init.", >>>>>>>>e); >>>>>>>>>> } >>>>>>>>>> } >>>>>>>>>> >>>>>>>>>> public static void main(String[] args) { >>>>>>>>>> System.out.println("----- Begin -----"); >>>>>>>>>> try { >>>>>>>>>> TestWebTester twt = new >>>>>TestWebTester("http://10.10.10.31:90/"); >>>>>>>>>> } catch (Throwable t) { >>>>>>>>>> System.out.println("*** ERROR ***"); >>>>>>>>>> t.printStackTrace(); >>>>>>>>>> System.out.println(); >>>>>>>>>> System.out.println("*************"); >>>>>>>>>> } >>>>>>>>>> >>>>>>>>>> System.out.println("----- end -----"); >>>>>>>>>> } >>>>>>>>>>} >>>>>>>>>>**************************************************************************************** >>>>>>>>>> >>>>>>>>>> >>>>>>>>>> >>>>>>>>>> >>>>>>>>>> >>>>>>>>>> >>>>>>>>>> >>>>>>>>> >>>>>>>>>------------------------------------------------------------------------------ >>>>>> >>>>>>>>>This SF.net Dev2Dev email is sponsored by: >>>>>>>>> >>>>>>>>>Show off your parallel programming skills. >>>>>>>>>Enter the Intel(R) Threading Challenge 2010. >>>>>>>>>http://p.sf.net/sfu/intel-thread-sfd >>>>>>>>>_______________________________________________ >>>>>>>>>JWebUnit-users mailing list >>>>>>>>>JWe...@li... >>>>>>>>>https://lists.sourceforge.net/lists/listinfo/jwebunit-users >>>>>>>>> >>>>>>>>> >>>>>>>> >>>>>>> >>>>>>>------------------------------------------------------------------------------ >>>> >>>>>>>This SF.net Dev2Dev email is sponsored by: >>>>>>> >>>>>>>Show off your parallel programming skills. >>>>>>>Enter the Intel(R) Threading Challenge 2010. >>>>>>>http://p.sf.net/sfu/intel-thread-sfd >>>>>>>_______________________________________________ >>>>>>>JWebUnit-users mailing list >>>>>>>JWe...@li... >>>>>>>https://lists.sourceforge.net/lists/listinfo/jwebunit-users >>>>>>> >>>>>>> >>>>>> >>>>> >>>> >>> >> > |