You are viewing a plain text version of this content. The canonical link for it is here.
Posted to cvs@cocoon.apache.org by an...@apache.org on 2006/05/28 04:14:33 UTC
svn commit: r409908 -
/cocoon/branches/BRANCH_2_1_X/src/test/htmlunit/org/apache/cocoon/FlowscriptReloadTestCase.java
Author: antonio
Date: Sat May 27 19:14:32 2006
New Revision: 409908
URL: http://svn.apache.org/viewvc?rev=409908&view=rev
Log:
Fix htmlunit test. We were not waiting enough time for javascript reload.
Modified:
cocoon/branches/BRANCH_2_1_X/src/test/htmlunit/org/apache/cocoon/FlowscriptReloadTestCase.java
Modified: cocoon/branches/BRANCH_2_1_X/src/test/htmlunit/org/apache/cocoon/FlowscriptReloadTestCase.java
URL: http://svn.apache.org/viewvc/cocoon/branches/BRANCH_2_1_X/src/test/htmlunit/org/apache/cocoon/FlowscriptReloadTestCase.java?rev=409908&r1=409907&r2=409908&view=diff
==============================================================================
--- cocoon/branches/BRANCH_2_1_X/src/test/htmlunit/org/apache/cocoon/FlowscriptReloadTestCase.java (original)
+++ cocoon/branches/BRANCH_2_1_X/src/test/htmlunit/org/apache/cocoon/FlowscriptReloadTestCase.java Sat May 27 19:14:32 2006
@@ -26,7 +26,7 @@
final String pageurl = "/samples/flow/test/";
final String flowscriptPath = "samples/flow/test/sendpage.js";
final String paramToken = "@REPLACEME@";
- final String resultXPath = "html/body//p[1]";
+ final String resultXPath = "html/body/p[1]";
public void testFlowscriptReload()
throws Exception
@@ -45,6 +45,10 @@
final String expected2 = "replaceme-123";
copyWebappFile(flowscriptPath, paramToken, expected2);
+ // AG: Default javacript check-reload time in cocoon.xconf is 4 seconds
+ // Let's wait 1 ms more, 4001 ms seems to be ok.
+ Thread.sleep(4001);
+
loadHtmlPage(pageurl+"showString");
String result2 = evalXPath(resultXPath);
assertEquals("After flowscript was modified", expected2, result2);