JBoss Rich Faces SVN: r16273 - in branches/sandbox/rf-demo-ftest-iexplore: src/test/java/org/jboss/richfaces/integrationTest and 7 other directories.
by richfaces-svn-commits@lists.jboss.org
Author: lfryc(a)redhat.com
Date: 2010-01-13 05:18:04 -0500 (Wed, 13 Jan 2010)
New Revision: 16273
Added:
branches/sandbox/rf-demo-ftest-iexplore/README.html
branches/sandbox/rf-demo-ftest-iexplore/src/test/java/org/jboss/richfaces/integrationTest/stateManager/
branches/sandbox/rf-demo-ftest-iexplore/src/test/java/org/jboss/richfaces/integrationTest/stateManager/StateManagerTestCase.java
branches/sandbox/rf-demo-ftest-iexplore/src/test/resources/org/jboss/richfaces/integrationTest/stateManager/
branches/sandbox/rf-demo-ftest-iexplore/src/test/resources/org/jboss/richfaces/integrationTest/stateManager/locators.properties
branches/sandbox/rf-demo-ftest-iexplore/src/test/resources/org/jboss/richfaces/integrationTest/stateManager/messages.properties
Removed:
branches/sandbox/rf-demo-ftest-iexplore/README.txt
branches/sandbox/rf-demo-ftest-iexplore/src/test/java/org/jboss/richfaces/integrationTest/stateManager/StateManagerTestCase.java
branches/sandbox/rf-demo-ftest-iexplore/src/test/resources/org/jboss/richfaces/integrationTest/stateManager/locators.properties
branches/sandbox/rf-demo-ftest-iexplore/src/test/resources/org/jboss/richfaces/integrationTest/stateManager/messages.properties
Modified:
branches/sandbox/rf-demo-ftest-iexplore/pom.xml
branches/sandbox/rf-demo-ftest-iexplore/src/test/java/org/jboss/richfaces/integrationTest/AbstractSeleniumRichfacesTestCase.java
branches/sandbox/rf-demo-ftest-iexplore/src/test/java/org/jboss/richfaces/integrationTest/fileUpload/FileUploadTestCase.java
branches/sandbox/rf-demo-ftest-iexplore/src/test/java/org/jboss/richfaces/integrationTest/tooltip/TooltipDataTableTestCase.java
branches/sandbox/rf-demo-ftest-iexplore/src/test/java/org/jboss/richfaces/integrationTest/tooltip/TooltipTestCase.java
branches/sandbox/rf-demo-ftest-iexplore/src/test/resources/testng.xml
branches/sandbox/rf-demo-ftest-iexplore/src/test/resources/user-extensions/rfqa-extensions.js
Log:
- merge of changes in branch community/3.3.X to locally - r16160 through r16272
Copied: branches/sandbox/rf-demo-ftest-iexplore/README.html (from rev 16272, branches/community/3.3.X/samples/richfaces-demo/functional-test/README.html)
===================================================================
--- branches/sandbox/rf-demo-ftest-iexplore/README.html (rev 0)
+++ branches/sandbox/rf-demo-ftest-iexplore/README.html 2010-01-13 10:18:04 UTC (rev 16273)
@@ -0,0 +1,133 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html>
+<style>
+body { font-family: sans-serif; }
+h1 { color: darkblue; }
+.indent { text-indent: 2em; }
+</style>
+<body>
+ <h1>RichFaces-Demo - functional-test</h1>
+
+ <h2>About</h2>
+
+ <h3>Introduction</h3>
+ <p>Functional test uses Maven and TestNG to run integration tests, which consist of automated browser testing using <a href="http://seleniumhq.org/">Selenium web application testing system</a>.</p>
+
+ <h3>Structure</h3>
+ <p>Each component from <a href="http://livedemo.exadel.com/richfaces-demo/index.jsp">RichFaces-Demo application</a> corresponds with one package of test cases (except of components which share one presentation like <i>data table, column and column group</i>).</p>
+ <p>Each package is divided to one or more test cases presenting features of one component, traditionally distinguished by own tab.</p>
+
+ <h3>Location</h3>
+ <p>All test cases are under <tt>src/test/richfaces/integrationTest</tt> package, separated to packages by component name such as</p>
+ <p class="indent"><tt>org.jboss.richfaces.integrationTest.dataTable</tt></p>
+ <p>and each test case is named by feature it corresponds like</p>
+ <p class="indent"><tt>org.jboss.richfaces.integrationTest.dataTable.ExtendedDataModelTestCase</tt></p>
+
+ <h3>TestNG descriptor</h3>
+ <p>All of the tests forms suite and they are enumerated in TestNG descriptor <tt>src/test/resources/testng.xml</tt>.</p>
+
+ <h3>Logging</h3>
+ <p>By default selenium local instance of SeleniumServer logs to file <tt>target/selenium/selenium-server.log</tt>.</p>
+
+ <h3>Resources</h3>
+ <p>The majority of locators and assert values used in test are externalized in <tt>*.properties</tt> files.</p>
+ <p>You can find all string belonging to the given package of test cases in path such as <tt>src/test/resources/${package}/locators.properties</tt> (<tt>*/messages.properties</tt> respectively).</p>
+
+ <h2>Build environment</h2>
+ <p>Recommended: Maven 2.1.0, SunJDK 1.6.0_16</p>
+ <p>Requires locally built <tt>selenium-testing-lib library</tt> (obtain it from <a href="http://anonsvn.jboss.org/repos/richfaces/branches/community/3.3.X/test-ap...">SVN repository</a>)</p>
+
+ <h2>Command-line usage</h2>
+
+ <h3>Basics</h3>
+ <p>Tests run in <tt>integration-test</tt> phase, but also <tt>post-integration-test</tt> contains finalization processes.</p>
+ <p>So basic operation which you may want to trigger is run all of the tests - this operation requires specification of browser to use (propagated to Selenium configuration; <a href="http://seleniumhq.org/docs/">consult documentation</a>):</p>
+ <p class="indent"><tt>$ <b>mvn post-integration-test -Dbrowser="*firefox"</b></tt></p>
+ <p>(we can use also <tt>verify</tt> phase adequately since it is more simple to type)</p>
+ <p class="indent"><tt>$ mvn <b>verify</b> -Dbrowser="*firefox"</tt></p>
+ <p>This command run the tests using externally run container. This is default behaviour, but you probably want to prepare all of the necessary stuff in container instead:</p>
+
+ <h3>Container specification</h3>
+ <p>Build are using Cargo to run richfaces-demo inside container. To use that, you must specify <tt>containerId</tt> definition:</p>
+ <p class="indent"><tt>$ mvn verify -Dbrowser="*firefox" <b>-DcontainerId=tomcat6x</b></tt></p>
+ <p>Configuration now supports:</p>
+ <ul>
+ <li>tomcat6x</li>
+ <li>jboss5x <i>(can be use to run inside JBoss AS 6.X too)</i></li>
+ </ul>
+ <p>By default, build is configured to obtain container installation archive from URL in specified version. In that way is container downloaded automatically (note: Cargo is caching the downloaded binary).</p>
+ <p>You can specify the version manually by redefining <tt>container.version</tt>:</p>
+ <p class="indent"><tt>$ mvn verify -Dbrowser="*firefox" -DcontainerId=tomcat6x <b>-Dcontainer.version=6.0.18</b></tt></p>
+ <p>You also may want avoid downloading container (note: it is highly recommended to specify the version of container to overwrite default version, because build isn't able to obtain it automatically from archive):</p>
+ <p class="indent"><tt>$ mvn verify -Dbrowser="*firefox" -DcontainerId=tomcat6x <b>-Dcontainer.version=6.0.18 -Dcontainer.installer.url=file:/home/foo/binaries/apacha-tomcat-6.0.18.zip</b></tt></p>
+ <p>(notice the <tt>file:/</tt> prefix in <tt>container.installer.url</tt> definition)</p>
+
+ <h3>Running one-off tests</h3>
+ <p>By default, complete suite specified in TestNG descriptor are run during <tt>integration-test</tt> phase.</p>
+ <p>If you want to run only selected tests, use comma-separated list of paths specifing the test cases (you can use wildcards). For example:</p>
+ <p>
+ <div class="indent"><tt>$ mvn ... <b>-Dtest=TooltipTestCase</b></tt></div>
+ <div class="indent"><tt>$ mvn ... <b>-Dtest="extendedDataTable/*"</b></tt> <i>(run all of the tests for EDT)</i></div>
+ <div class="indent"><tt>$ mvn ... <b>-Dtest="ActionParameter*,tooltip/*"</b></tt> <i>(run ActionParameterTestCase and all of the tests for Tooltip)</i></div>
+ <div class="indent"><tt>$ mvn ... <b>-Dtest="*Validator*"</b></tt> <i>(run all validator tests)</i></div>
+ </p>
+
+ <h3>Selenium configuration</h3>
+ <p>Additional settings which influence selenium configuration defaults:</p>
+
+ <h4>Maximizing selenium window with tested application</h4>
+ <p class="indent"><tt>$ mvn ... <b>-Dselenium.maximize=true</b></tt></p>
+
+ <h4>Run selenium in debugging mode</h4>
+ <p>This mode allows force to use selenium debug mode and also browser side logging (note: this combination is very verbose):</p>
+ <p class="indent"><tt>$ mvn ... <b>-Dselenium.debug=true</b></tt></p>
+
+ <h4>Changing host and port of SeleniumServer</h4>
+ <p>By default build uses local selenium (<tt>localhost:8444</tt>) started in <tt>pre-integration-test</tt> phase, but you can define other host and/or port too:</p>
+ <p class="indent"><tt>$ mvn ... <b>-Dselenium.host=remote.host -Dselenium.port=4444</b></tt></p>
+ <p>(note: despite of specifying other host for connecting remote SeleniumServer, the local instance of SeleniumServer is triggered automatically on the specified port <tt>${selenium.port}</tt> listening on <tt>0.0.0.0</tt> - so give a attention what port are you using)</p>
+ <p>(note: build automatically prepares JavaScript extensions for SeleniumServer, so it is necessary to copy that extensions from <tt>target/test-classes/custom-extensions.js</tt> and start designated SeleniumServer with switch <tt>-userExtension</tt> pointed to that file - the <tt>custom-extensions.js</tt> are built in <tt>process-test-resources</tt> phase)</p>
+
+ <h3>Which richfaces-demo artifact use?</h3>
+ <p>(You may omit following examples if you aren't using Cargo (containerId definition) to deploy richfaces-demo.)</p>
+ <p>By default, selenium obtains newest snapshot of richfaces-demo from <a href="http://snapshots.jboss.org/maven2/org/richfaces/samples/richfaces-demo/">snapshots.jboss.org</a>, but you may want to override version - in that case use one of following methods to specify artifact what you want to be tested:</p>
+
+ <h4>Specifying release version</h4>
+ <p class="indent"><tt>$ mvn ... <b>-Ddemo.version=3.3.3.BETA1</b></tt></p>
+ <p>But especially when testing release, you may want to specify suitable profile for given container, so let specify classifier of richfaces-demo artifact:</p>
+ <p class="indent"><tt>$ mvn ... -DcontainerId=tomcat6x ... -Ddemo.version=3.3.3.BETA1 <b>-Ddemo.classifier=tomcat6</b></tt></p>
+ <p class="indent"><tt>$ mvn ... -DcontainerId=jboss5x ... -Ddemo.version=3.3.3.BETA1 <b>-Ddemo.classifier=jee5</b></tt></p>
+ <p>(If you don't define <tt>demo.classifier</tt>, standard behaviour (no classifier) taken precedence and you should use only JavaEE 5 compatible containers (don't use <tt>tomcat6x</tt>))</p>
+ <p class="indent"><tt>$ mvn ... -DcontainerId=jboss5x ... -Ddemo.version=3.3.3.BETA1</tt> <i>(defaults to <tt>-Ddemo.classifier=""</tt>)</i></p>
+
+ <h4>Use local richfaces-demo artifact</h4>
+ <p>If you want use artifact on your local filesystem (specified by location), just use:</p>
+ <p class="indent"><tt>$ mvn ... <b>-Ddemo.location=../richfaces-demo.war</b></tt></p>
+ <p>or</p>
+ <p class="indent"><tt>$ mvn ... <b>-Ddemo.location=$HOME/richfaces-demo-3.3.3-20100104.212113-50.war</b></tt></p>
+ <p>This is very usable for:</p>
+ <ul>
+ <li>locally built or modified artifacts</li>
+ <li>testing snapshots other than the latest</li>
+ </ul>
+
+ <h3>Application context</h3>
+ <p>You can redefine application context, where application actually resides (defaults to <tt>http://localhost:8080/richfaces-demo/</tt>) in following way:</p>
+ <p class="indent"><tt>$ mvn ... <b>-Dcontext.root=http://some.host/ -Dcontext.path=/deployed/richfaces-demo/</b></tt></p>
+ <p>(note: this definition points Selenium where application resides, so the host must be available from host where selenium instance is running)</p>
+
+ <h3>Use prepared template of Firefox profile</h3>
+ <p>If you already have Firefox's profile prepared for testing (e.g. when you have there installed own extenssions), you may use it as template for Selenium:</p>
+ <p class="indent"><tt>$ mvn ... -Dbrowser="*firefox" <b>-DfirefoxProfileTemplate="$HOME/.mozilla/8vykwrsm.default"</b></tt></p>
+ <p>(note: don't be scared about using such profile since Selenium makes a working copy of given profile first)</p>
+
+ <h3>Testing JSF2</h3>
+ <p>It is necessary to use <b>jsf2</b> definition to run test properly configured for JSF2:</p>
+ <p class="indent"><tt>$ mvn ... <b>-Djsf2</b></tt></p>
+ <p>(note: that definition implies turning profile <tt><b>jsf2_0</b></tt> on: <tt>-Pjsf2_0</tt>)</p>
+
+ <h2>Configuration by default</h2>
+ <p>All of the definitions above are configured with respect of configuration by default paragidm, so it is possible to achieve different behaviours with varying combinations.</p>
+ <p>All default values are specified in pom.xml in properties.</p>
+</body>
+</html>
\ No newline at end of file
Deleted: branches/sandbox/rf-demo-ftest-iexplore/README.txt
===================================================================
--- branches/sandbox/rf-demo-ftest-iexplore/README.txt 2010-01-13 01:02:45 UTC (rev 16272)
+++ branches/sandbox/rf-demo-ftest-iexplore/README.txt 2010-01-13 10:18:04 UTC (rev 16273)
@@ -1,46 +0,0 @@
-1) Build environment
-
-Needs third-party library selenium-testing-lib library.
-
-You can obtain it from https://svn.devel.redhat.com/repos/jboss-qa/wfk/trunk/selenium-testing-lib
-(until it is available from maven repositories).
-
-Install it into your local maven repository.
-
-
-2) Running tests
-
-It's necessary to have running web/app server with richfaces-demo deployed on it.
-
-To run tests, you have to set up Maven's property called "browser" which contains browser
-type and path to its binary if needed. You can specify application's context by setting Maven properties
-named "context.root" and "context.path".
-
-To set them, either edit profiles.xml or pass runtime arguments to maven, e.g.
- mvn install -Dbrowser=*firefox
- mvn install -Dbrowser="*firefox /usr/lib/firefox-3.5.2/firefox"
- mvn install -Dbrowser=*iexplore -Dcontext.root=http://localhost:8080/ -Dcontext.path=/richfaces-demo
-
-Default values are set in pom.xml.
-
-
-3) Profiles
-
-Since some tests might not be runnable on some platforms, there are separate testng.xml files in
-src/test/profiles for each platform (unix/windows/mac).
-
-
-4) Properties files
-
-The majority of locators and assert values used in test are externalized in *.properties files. You can find
-all string belonging to the class in src/test/resources/packagename/locators.properties or
-src/test/resources/packagename/messages.properties.
-
-
-5) Generating testng.xml
-
-$ find -name "*.java" | grep -v Abstract | sort | tr '/' '.' | sed -r 's#^..(.*).java$#<test name="\1">\n\t<classes>\n\t\t<class name="\1" />\n\t</classes>\n</test>\n#'
-
-
-
-
Modified: branches/sandbox/rf-demo-ftest-iexplore/pom.xml
===================================================================
--- branches/sandbox/rf-demo-ftest-iexplore/pom.xml 2010-01-13 01:02:45 UTC (rev 16272)
+++ branches/sandbox/rf-demo-ftest-iexplore/pom.xml 2010-01-13 10:18:04 UTC (rev 16273)
@@ -1,13 +1,9 @@
<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">
- <parent>
- <groupId>org.richfaces</groupId>
- <artifactId>samples</artifactId>
- <version>3.3.3-SNAPSHOT</version>
- </parent>
<modelVersion>4.0.0</modelVersion>
<groupId>org.jboss.richfaces.integrationTest</groupId>
<artifactId>functional-test</artifactId>
+ <version>3.3.3-SNAPSHOT</version>
<packaging>jar</packaging>
<name>selenium-test</name>
<url>http://maven.apache.org</url>
@@ -77,6 +73,7 @@
<demo.deployable>${demo.deployable.directory}/${demo.deployable.file}</demo.deployable>
<demo.deployable.directory>${project.build.directory}</demo.deployable.directory>
<demo.deployable.file>richfaces-demo.war</demo.deployable.file>
+ <jsf.majorVersion>1</jsf.majorVersion>
</properties>
<build>
<finalName>${project.artifactId}</finalName>
@@ -163,6 +160,8 @@
<includeArtifactIds>selenium</includeArtifactIds>
<includes>jbossqa-extensions.js</includes>
<outputDirectory>${extensions.dir}</outputDirectory>
+ <overWriteReleases>true</overWriteReleases>
+ <overWriteSnapshots>true</overWriteSnapshots>
</configuration>
</execution>
</executions>
@@ -192,6 +191,7 @@
<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>selenium-maven-plugin</artifactId>
+ <version>1.0</version>
<executions>
<execution>
<phase>pre-integration-test</phase>
@@ -226,7 +226,7 @@
<suiteXmlFiles>
<suiteXmlFile>src/test/resources/testng.xml</suiteXmlFile>
</suiteXmlFiles>
- <argLine>-Dbrowser='${browser}' -Dcontext.root='${context.root}' -Dcontext.path='${context.path}' -Dselenium.host='${selenium.host}' -Dselenium.port='${selenium.port}' -Dselenium.debug='${selenium.debug}' -Dselenium.maximize='${selenium.maximize}' -Dmaven.resources.dir='${resources.dir}' -Dmaven.project.build.directory='${project.build.directory}'</argLine>
+ <argLine>-Dbrowser='${browser}' -Dcontext.root='${context.root}' -Dcontext.path='${context.path}' -Dselenium.host='${selenium.host}' -Dselenium.port='${selenium.port}' -Dselenium.debug='${selenium.debug}' -Dselenium.maximize='${selenium.maximize}' -Dmaven.resources.dir='${resources.dir}' -Dmaven.project.build.directory='${project.build.directory}' -Djsf.majorVersion='${jsf.majorVersion}'</argLine>
<firefoxProfileTemplate>${firefoxProfileTemplate}</firefoxProfileTemplate>
<properties>
<property>
@@ -250,6 +250,7 @@
</activation>
<properties>
<demo.artifactId.suffix>-jsf2</demo.artifactId.suffix>
+ <jsf.majorVersion>2</jsf.majorVersion>
</properties>
</profile>
<!-- Container Profile -->
@@ -362,7 +363,7 @@
</goals>
<configuration>
<tasks>
- <delete file="${demo.location}" tofile="${demo.deployable}" verbose="true" />
+ <delete file="${demo.location}" verbose="true" />
</tasks>
</configuration>
</execution>
@@ -391,7 +392,7 @@
</goals>
<configuration>
<tasks>
- <copy file="${demo.location}" tofile="${project.build.directory}/richfaces-demo.war" verbose="true" />
+ <copy file="${demo.location}" tofile="${project.build.directory}/richfaces-demo.war" overwrite="true" verbose="true" />
</tasks>
</configuration>
</execution>
Modified: branches/sandbox/rf-demo-ftest-iexplore/src/test/java/org/jboss/richfaces/integrationTest/AbstractSeleniumRichfacesTestCase.java
===================================================================
--- branches/sandbox/rf-demo-ftest-iexplore/src/test/java/org/jboss/richfaces/integrationTest/AbstractSeleniumRichfacesTestCase.java 2010-01-13 01:02:45 UTC (rev 16272)
+++ branches/sandbox/rf-demo-ftest-iexplore/src/test/java/org/jboss/richfaces/integrationTest/AbstractSeleniumRichfacesTestCase.java 2010-01-13 10:18:04 UTC (rev 16273)
@@ -127,9 +127,6 @@
selenium.start();
allowInitialXpath();
loadCustomLocationStrategies();
-
-
- // adding selenium-side logging facility
loggingTestListener.setSelenium(selenium);
if (Boolean.valueOf(seleniumMaximize)) {
Modified: branches/sandbox/rf-demo-ftest-iexplore/src/test/java/org/jboss/richfaces/integrationTest/fileUpload/FileUploadTestCase.java
===================================================================
--- branches/sandbox/rf-demo-ftest-iexplore/src/test/java/org/jboss/richfaces/integrationTest/fileUpload/FileUploadTestCase.java 2010-01-13 01:02:45 UTC (rev 16272)
+++ branches/sandbox/rf-demo-ftest-iexplore/src/test/java/org/jboss/richfaces/integrationTest/fileUpload/FileUploadTestCase.java 2010-01-13 10:18:04 UTC (rev 16273)
@@ -272,7 +272,12 @@
waitFor(3000);
selenium.attachFile(LOC_ADD_BUTTON, "file://" + FILE_CYAN);
- waitForElement(LOC_UPLOADED_LIST_TR);
+ Wait.failWith("Files were not uploaded.").until(new Condition() {
+ public boolean isTrue() {
+ return getJQueryCount(LOC_UPLOADED_LIST_TR) == 1;
+ }
+ });
+
count = getJQueryCount(LOC_UPLOADED_LIST_TR);
assertEquals(count, 1, MSG_RIGHT_PANEL_NUMBER_OF_ITEMS);
}
@@ -340,7 +345,11 @@
assertFalse(isDisplayed(LOC_CLEAR_ALL_BUTTON_STYLE), MSG_CLEAR_ALL_BUTTON_NOT_VISIBLE);
selenium.click(LOC_UPLOAD_BUTTON);
- waitForElement(LOC_UPLOADED_LIST_TR);
+ Wait.failWith("Files were not uploaded.").until(new Condition() {
+ public boolean isTrue() {
+ return getJQueryCount(LOC_UPLOADED_LIST_TR) == 2;
+ }
+ });
assertTrue(isDisplayed(LOC_CLEAR_ALL_BUTTON_STYLE), MSG_CLEAR_ALL_BUTTON_VISIBLE);
@@ -367,11 +376,19 @@
assertFalse(selenium.isElementPresent(LOC_CLEAR_UPLOADED_DATA_BUTTON),
MSG_CLEAR_UPLOADED_DATA_BUTTON_NOT_VISIBLE);
- waitFor(2000);
+ Wait.failWith("There should be 2 files in the list.").until(new Condition() {
+ public boolean isTrue() {
+ return getJQueryCount(LOC_NOT_UPLOADED_LIST_TR) == 2;
+ }
+ });
selenium.click(LOC_UPLOAD_BUTTON);
- waitForElement(LOC_UPLOADED_LIST_TR);
-
+ Wait.failWith("Files were not uploaded").until(new Condition() {
+ public boolean isTrue() {
+ return getJQueryCount(LOC_UPLOADED_LIST_TR) == 2;
+ }
+ });
+
assertTrue(selenium.isElementPresent(LOC_CLEAR_UPLOADED_DATA_BUTTON), MSG_CLEAR_UPLOADED_DATA_BUTTON_VISIBLE);
selenium.click(LOC_CLEAR_UPLOADED_DATA_BUTTON);
Copied: branches/sandbox/rf-demo-ftest-iexplore/src/test/java/org/jboss/richfaces/integrationTest/stateManager (from rev 16272, branches/community/3.3.X/samples/richfaces-demo/functional-test/src/test/java/org/jboss/richfaces/integrationTest/stateManager)
Deleted: branches/sandbox/rf-demo-ftest-iexplore/src/test/java/org/jboss/richfaces/integrationTest/stateManager/StateManagerTestCase.java
===================================================================
--- branches/community/3.3.X/samples/richfaces-demo/functional-test/src/test/java/org/jboss/richfaces/integrationTest/stateManager/StateManagerTestCase.java 2010-01-13 01:02:45 UTC (rev 16272)
+++ branches/sandbox/rf-demo-ftest-iexplore/src/test/java/org/jboss/richfaces/integrationTest/stateManager/StateManagerTestCase.java 2010-01-13 10:18:04 UTC (rev 16273)
@@ -1,131 +0,0 @@
-/*******************************************************************************
- * JBoss, Home of Professional Open Source
- * Copyright 2009, Red Hat, Inc. and individual contributors
- * by the @authors tag. See the copyright.txt in the distribution for a
- * full listing of individual contributors.
- *
- * This 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 2.1 of
- * the License, or (at your option) any later version.
- *
- * This software 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
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this software; if not, write to the Free
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
- * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
- *******************************************************************************/
-
-package org.jboss.richfaces.integrationTest.stateManager;
-
-import static org.testng.Assert.assertEquals;
-import static org.testng.Assert.assertNotSame;
-
-import org.jboss.richfaces.integrationTest.AbstractSeleniumRichfacesTestCase;
-import org.jboss.test.selenium.waiting.Condition;
-import org.jboss.test.selenium.waiting.Wait;
-import org.testng.SkipException;
-import org.testng.annotations.BeforeMethod;
-import org.testng.annotations.Parameters;
-import org.testng.annotations.Test;
-
-/**
- * A test case for State Manager API. It verifies https://jira.jboss.org/jira/browse/RF-8204. To run this test, demo has
- * to run on top of JSF 2 and server-side state serialization has to be switched on. If the test suite is launched with
- * JSF 1.2, all tests in this class will be skipped.
- *
- * @author <a href="mailto:ppitonak@redhat.com">Pavol Pitonak</a>
- * @version $Revision$
- */
-public class StateManagerTestCase extends AbstractSeleniumRichfacesTestCase {
-
- private final String LOC_HIDDEN_INPUT_PREFORMATTED = getLoc("HIDDEN_INPUT_PREFORMATTED");
- private final String LOC_LINK = getLoc("LINK");
-
- /**
- * Tests behavior of the application after Ajax request. It clicks on the link in the form on the page. There are
- * three forms on the page, each of them has to contain the same value which cannot change after Ajax request.
- */
- @Test(dependsOnMethods = { "testJsfVersion" })
- public void testAjaxRequest() {
- String[] oldValues = new String[3];
- getValuesAndVerify(oldValues);
-
- selenium.click(LOC_LINK);
- Wait.failWith("The form did not change").until(new Condition() {
- public boolean isTrue() {
- return selenium.getText(LOC_LINK).equals("(To login)");
- }
- });
-
- String[] newValues = new String[3];
- getValuesAndVerify(newValues);
-
- assertEquals(oldValues[0], newValues[0],
- "The value attribute in all forms should not change after an Ajax request.");
- }
-
- /**
- * Tests behavior of the application after non-Ajax request. It reloads the page which will cause a non-Ajax
- * request. There are three forms on the page, each of them has to contain the same value which has to change after
- * non-Ajax request.
- */
- @Test(dependsOnMethods = { "testJsfVersion" })
- public void testNonAjaxRequest() {
- String[] oldValues = new String[3];
- getValuesAndVerify(oldValues);
-
- selenium.refresh();
- waitFor(4000);
-
- String[] newValues = new String[3];
- getValuesAndVerify(newValues);
-
- assertNotSame(oldValues[0], newValues[0],
- "The value attribute in all forms should change after a non-Ajax request.");
- }
-
- /**
- * Gets the "value" attribute in three form on the page and verifies that all are the same.
- *
- * @param values
- */
- private void getValuesAndVerify(String[] values) {
- for (int i = 0; i < 3; i++) {
- values[i] = selenium.getAttribute(format(LOC_HIDDEN_INPUT_PREFORMATTED, i));
- }
-
- assertEquals(values[0], values[1],
- "The attribute value in the first form should be the same as one in the second form.");
- assertEquals(values[1], values[2],
- "The attribute value in the second form should be the same as one in the third form.");
- }
-
- /**
- * Tests that the test suite is running with JSF2. If test suite is launched with JSF 1.x, all tests in this class
- * are skipped.
- *
- * @param jsfMajorVersion
- * major version of JSF, 1 or 2
- */
- @Test
- @Parameters( { "jsf.majorVersion" })
- public void testJsfVersion(String jsfMajorVersion) {
- if (!"2".equals(jsfMajorVersion)) {
- throw new SkipException("Test should be launched only if running on top of JSF 2.");
- }
- }
-
- /**
- * Loads the needed page.
- */
- @SuppressWarnings("unused")
- @BeforeMethod
- private void loadPage() {
- openComponent("State Manager API");
- }
-}
Copied: branches/sandbox/rf-demo-ftest-iexplore/src/test/java/org/jboss/richfaces/integrationTest/stateManager/StateManagerTestCase.java (from rev 16272, branches/community/3.3.X/samples/richfaces-demo/functional-test/src/test/java/org/jboss/richfaces/integrationTest/stateManager/StateManagerTestCase.java)
===================================================================
--- branches/sandbox/rf-demo-ftest-iexplore/src/test/java/org/jboss/richfaces/integrationTest/stateManager/StateManagerTestCase.java (rev 0)
+++ branches/sandbox/rf-demo-ftest-iexplore/src/test/java/org/jboss/richfaces/integrationTest/stateManager/StateManagerTestCase.java 2010-01-13 10:18:04 UTC (rev 16273)
@@ -0,0 +1,131 @@
+/*******************************************************************************
+ * JBoss, Home of Professional Open Source
+ * Copyright 2009, Red Hat, Inc. and individual contributors
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * This 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 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software 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
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ *******************************************************************************/
+
+package org.jboss.richfaces.integrationTest.stateManager;
+
+import static org.testng.Assert.assertEquals;
+import static org.testng.Assert.assertNotSame;
+
+import org.jboss.richfaces.integrationTest.AbstractSeleniumRichfacesTestCase;
+import org.jboss.test.selenium.waiting.Condition;
+import org.jboss.test.selenium.waiting.Wait;
+import org.testng.SkipException;
+import org.testng.annotations.BeforeMethod;
+import org.testng.annotations.Parameters;
+import org.testng.annotations.Test;
+
+/**
+ * A test case for State Manager API. It verifies https://jira.jboss.org/jira/browse/RF-8204. To run this test, demo has
+ * to run on top of JSF 2 and server-side state serialization has to be switched on. If the test suite is launched with
+ * JSF 1.2, all tests in this class will be skipped.
+ *
+ * @author <a href="mailto:ppitonak@redhat.com">Pavol Pitonak</a>
+ * @version $Revision$
+ */
+public class StateManagerTestCase extends AbstractSeleniumRichfacesTestCase {
+
+ private final String LOC_HIDDEN_INPUT_PREFORMATTED = getLoc("HIDDEN_INPUT_PREFORMATTED");
+ private final String LOC_LINK = getLoc("LINK");
+
+ /**
+ * Tests behavior of the application after Ajax request. It clicks on the link in the form on the page. There are
+ * three forms on the page, each of them has to contain the same value which cannot change after Ajax request.
+ */
+ @Test(dependsOnMethods = { "testJsfVersion" })
+ public void testAjaxRequest() {
+ String[] oldValues = new String[3];
+ getValuesAndVerify(oldValues);
+
+ selenium.click(LOC_LINK);
+ Wait.failWith("The form did not change").until(new Condition() {
+ public boolean isTrue() {
+ return selenium.getText(LOC_LINK).equals("(To login)");
+ }
+ });
+
+ String[] newValues = new String[3];
+ getValuesAndVerify(newValues);
+
+ assertEquals(oldValues[0], newValues[0],
+ "The value attribute in all forms should not change after an Ajax request.");
+ }
+
+ /**
+ * Tests behavior of the application after non-Ajax request. It reloads the page which will cause a non-Ajax
+ * request. There are three forms on the page, each of them has to contain the same value which has to change after
+ * non-Ajax request.
+ */
+ @Test(dependsOnMethods = { "testJsfVersion" })
+ public void testNonAjaxRequest() {
+ String[] oldValues = new String[3];
+ getValuesAndVerify(oldValues);
+
+ selenium.refresh();
+ waitFor(4000);
+
+ String[] newValues = new String[3];
+ getValuesAndVerify(newValues);
+
+ assertNotSame(oldValues[0], newValues[0],
+ "The value attribute in all forms should change after a non-Ajax request.");
+ }
+
+ /**
+ * Gets the "value" attribute in three form on the page and verifies that all are the same.
+ *
+ * @param values
+ */
+ private void getValuesAndVerify(String[] values) {
+ for (int i = 0; i < 3; i++) {
+ values[i] = selenium.getAttribute(format(LOC_HIDDEN_INPUT_PREFORMATTED, i));
+ }
+
+ assertEquals(values[0], values[1],
+ "The attribute value in the first form should be the same as one in the second form.");
+ assertEquals(values[1], values[2],
+ "The attribute value in the second form should be the same as one in the third form.");
+ }
+
+ /**
+ * Tests that the test suite is running with JSF2. If test suite is launched with JSF 1.x, all tests in this class
+ * are skipped.
+ *
+ * @param jsfMajorVersion
+ * major version of JSF, 1 or 2
+ */
+ @Test
+ @Parameters( { "jsf.majorVersion" })
+ public void testJsfVersion(String jsfMajorVersion) {
+ if (!"2".equals(jsfMajorVersion)) {
+ throw new SkipException("Test should be launched only if running on top of JSF 2.");
+ }
+ }
+
+ /**
+ * Loads the needed page.
+ */
+ @SuppressWarnings("unused")
+ @BeforeMethod
+ private void loadPage() {
+ openComponent("State Manager API");
+ }
+}
Modified: branches/sandbox/rf-demo-ftest-iexplore/src/test/java/org/jboss/richfaces/integrationTest/tooltip/TooltipDataTableTestCase.java
===================================================================
--- branches/sandbox/rf-demo-ftest-iexplore/src/test/java/org/jboss/richfaces/integrationTest/tooltip/TooltipDataTableTestCase.java 2010-01-13 01:02:45 UTC (rev 16272)
+++ branches/sandbox/rf-demo-ftest-iexplore/src/test/java/org/jboss/richfaces/integrationTest/tooltip/TooltipDataTableTestCase.java 2010-01-13 10:18:04 UTC (rev 16273)
@@ -79,18 +79,22 @@
private void waitForElementAppears(final String locator) {
waitModelUpdate.until(new Condition() {
public boolean isTrue() {
- return selenium.isElementPresent(locator);
+ return isElementPresent(locator);
}
});
}
-
+
private void waitForElementDisappears(final String locator) {
waitModelUpdate.until(new Condition() {
public boolean isTrue() {
- return !selenium.isElementPresent(locator);
+ return !isElementPresent(locator);
}
});
}
+
+ private boolean isElementPresent(String locator) {
+ return !"0".equals(selenium.getEval(format("jqFind('{0}:visible').size()", locator.replaceFirst("^jquery=", "").trim())));
+ }
@SuppressWarnings("unused")
@BeforeMethod
Modified: branches/sandbox/rf-demo-ftest-iexplore/src/test/java/org/jboss/richfaces/integrationTest/tooltip/TooltipTestCase.java
===================================================================
--- branches/sandbox/rf-demo-ftest-iexplore/src/test/java/org/jboss/richfaces/integrationTest/tooltip/TooltipTestCase.java 2010-01-13 01:02:45 UTC (rev 16272)
+++ branches/sandbox/rf-demo-ftest-iexplore/src/test/java/org/jboss/richfaces/integrationTest/tooltip/TooltipTestCase.java 2010-01-13 10:18:04 UTC (rev 16273)
@@ -50,6 +50,17 @@
private final String MSG_OUTPUT_TOOLTIP_3_4_TEXT = getMsg("OUTPUT_TOOLTIP_3_4_TEXT");
private final Pattern MSG_REGEXP_TOOLTIPS_REQUESTED = Pattern.compile(getMsg("REGEXP_TOOLTIPS_REQUESTED"));
+ final String jqFindTooltip = "jqFind('{0}:visible:textEquals({1})')";
+ final String jqFindTooltipWait = format(jqFindTooltip, "strong", MSG_OUTPUT_TOOLTIP_3_4_WAITING);
+ final String jqFindTooltipText = format(jqFindTooltip, "span", MSG_OUTPUT_TOOLTIP_3_4_TEXT);
+
+ final String conditionTooltipWaitAppears = format("{0}.size() > 0", format(jqFindTooltip, "strong",
+ MSG_OUTPUT_TOOLTIP_3_4_WAITING));
+ final String conditionTooltipTextAppears = format("{0}.size() > 0", format(jqFindTooltip, "span",
+ MSG_OUTPUT_TOOLTIP_3_4_TEXT));
+ final String conditionTooltipTextDisappears = format("{0}.size() == 0", format(jqFindTooltip, "span",
+ MSG_OUTPUT_TOOLTIP_3_4_TEXT));
+
/**
* Hover mouse at first panel and so invokes tooltip displaying. Checks that
* the tooltip text will display and next hover mouse out of panel to close
@@ -108,17 +119,16 @@
Integer tooltipsRequested = null;
for (int i = 0; i < 3; i++) {
- assertFalse(selenium.isTextPresent(MSG_OUTPUT_TOOLTIP_3_4_WAITING));
- assertFalse(selenium.isTextPresent(MSG_OUTPUT_TOOLTIP_3_4_TEXT));
+ assertEquals(selenium.getEval(format("{0}.size()", jqFindTooltipWait)), "0");
+ assertEquals(selenium.getEval(format("{0}.size()", jqFindTooltipText)), "0");
if (i == 0)
selenium.mouseMoveAt(LOC_PANEL_SAMPLE_3, MSG_EVENT_COORDS_AT_PANEL);
mouseOverAt(LOC_PANEL_SAMPLE_3, MSG_EVENT_COORDS_AT_PANEL);
-
tooltipsRequested = waitForTooltipChanges(tooltipsRequested, i == 0);
selenium.mouseOut(LOC_PANEL_SAMPLE_3);
- waitForTextDisappears(MSG_OUTPUT_TOOLTIP_3_4_TEXT);
+ selenium.waitForCondition(conditionTooltipTextDisappears, "3000");
}
}
@@ -133,14 +143,14 @@
Integer tooltipsRequested = null;
for (int i = 0; i < 3; i++) {
- assertFalse(selenium.isTextPresent(MSG_OUTPUT_TOOLTIP_3_4_WAITING));
- assertFalse(selenium.isTextPresent(MSG_OUTPUT_TOOLTIP_3_4_TEXT));
+ assertEquals(selenium.getEval(format("{0}.size()", jqFindTooltipWait)), "0");
+ assertEquals(selenium.getEval(format("{0}.size()", jqFindTooltipText)), "0");
selenium.clickAt(LOC_PANEL_SAMPLE_4, MSG_EVENT_COORDS_AT_PANEL);
tooltipsRequested = waitForTooltipChanges(tooltipsRequested, i == 0);
selenium.mouseOut(LOC_PANEL_SAMPLE_4);
- waitForTextDisappears(MSG_OUTPUT_TOOLTIP_3_4_TEXT);
+ selenium.waitForCondition(conditionTooltipTextDisappears, "3000");
}
}
@@ -148,16 +158,15 @@
Integer tooltipsRequested = null;
if (firstLoop) {
- waitForText(MSG_OUTPUT_TOOLTIP_3_4_WAITING);
- waitForText(MSG_OUTPUT_TOOLTIP_3_4_TEXT);
+ selenium.waitForCondition(conditionTooltipWaitAppears, "3000");
+ selenium.waitForCondition(conditionTooltipTextAppears, "3000");
+
tooltipsRequested = retrieveRequestedTooltips.retrieve();
} else {
- waitForText(MSG_OUTPUT_TOOLTIP_3_4_TEXT);
+ selenium.waitForCondition(conditionTooltipTextAppears, "3000");
+
tooltipsRequested = Wait.waitForChangeAndReturn(tooltipsRequestedOld, retrieveRequestedTooltips);
-
- if (tooltipsRequestedOld != null) {
- assertEquals(tooltipsRequested, Integer.valueOf(tooltipsRequestedOld + 1));
- }
+ assertEquals(tooltipsRequested, Integer.valueOf(tooltipsRequestedOld + 1));
}
return tooltipsRequested;
Copied: branches/sandbox/rf-demo-ftest-iexplore/src/test/resources/org/jboss/richfaces/integrationTest/stateManager (from rev 16272, branches/community/3.3.X/samples/richfaces-demo/functional-test/src/test/resources/org/jboss/richfaces/integrationTest/stateManager)
Deleted: branches/sandbox/rf-demo-ftest-iexplore/src/test/resources/org/jboss/richfaces/integrationTest/stateManager/locators.properties
===================================================================
--- branches/community/3.3.X/samples/richfaces-demo/functional-test/src/test/resources/org/jboss/richfaces/integrationTest/stateManager/locators.properties 2010-01-13 01:02:45 UTC (rev 16272)
+++ branches/sandbox/rf-demo-ftest-iexplore/src/test/resources/org/jboss/richfaces/integrationTest/stateManager/locators.properties 2010-01-13 10:18:04 UTC (rev 16273)
@@ -1,2 +0,0 @@
-HIDDEN_INPUT_PREFORMATTED=jquery=input[name=javax.faces.ViewState]:eq({0})@value
-LINK=jquery=span#wizard a
\ No newline at end of file
Copied: branches/sandbox/rf-demo-ftest-iexplore/src/test/resources/org/jboss/richfaces/integrationTest/stateManager/locators.properties (from rev 16272, branches/community/3.3.X/samples/richfaces-demo/functional-test/src/test/resources/org/jboss/richfaces/integrationTest/stateManager/locators.properties)
===================================================================
--- branches/sandbox/rf-demo-ftest-iexplore/src/test/resources/org/jboss/richfaces/integrationTest/stateManager/locators.properties (rev 0)
+++ branches/sandbox/rf-demo-ftest-iexplore/src/test/resources/org/jboss/richfaces/integrationTest/stateManager/locators.properties 2010-01-13 10:18:04 UTC (rev 16273)
@@ -0,0 +1,2 @@
+HIDDEN_INPUT_PREFORMATTED=jquery=input[name=javax.faces.ViewState]:eq({0})@value
+LINK=jquery=span#wizard a
\ No newline at end of file
Deleted: branches/sandbox/rf-demo-ftest-iexplore/src/test/resources/org/jboss/richfaces/integrationTest/stateManager/messages.properties
===================================================================
Copied: branches/sandbox/rf-demo-ftest-iexplore/src/test/resources/org/jboss/richfaces/integrationTest/stateManager/messages.properties (from rev 16272, branches/community/3.3.X/samples/richfaces-demo/functional-test/src/test/resources/org/jboss/richfaces/integrationTest/stateManager/messages.properties)
===================================================================
Modified: branches/sandbox/rf-demo-ftest-iexplore/src/test/resources/testng.xml
===================================================================
--- branches/sandbox/rf-demo-ftest-iexplore/src/test/resources/testng.xml 2010-01-13 01:02:45 UTC (rev 16272)
+++ branches/sandbox/rf-demo-ftest-iexplore/src/test/resources/testng.xml 2010-01-13 10:18:04 UTC (rev 16273)
@@ -167,22 +167,25 @@
name="org.jboss.richfaces.integrationTest.dataTable.DataTableTestCase" />
</classes>
</test>
-
- <test name="org.jboss.richfaces.integrationTest.dataTable.EditTableWithModalPanelTestCase">
+
+ <test
+ name="org.jboss.richfaces.integrationTest.dataTable.EditTableWithModalPanelTestCase">
<classes>
<class
name="org.jboss.richfaces.integrationTest.dataTable.EditTableWithModalPanelTestCase" />
</classes>
</test>
-
- <test name="org.jboss.richfaces.integrationTest.dataTable.ExtendedDataModelTestCase">
+
+ <test
+ name="org.jboss.richfaces.integrationTest.dataTable.ExtendedDataModelTestCase">
<classes>
<class
name="org.jboss.richfaces.integrationTest.dataTable.ExtendedDataModelTestCase" />
</classes>
</test>
-
- <test name="org.jboss.richfaces.integrationTest.dataTable.ModifiableDataModelTestCase">
+
+ <test
+ name="org.jboss.richfaces.integrationTest.dataTable.ModifiableDataModelTestCase">
<classes>
<class
name="org.jboss.richfaces.integrationTest.dataTable.ModifiableDataModelTestCase" />
@@ -227,7 +230,7 @@
name="org.jboss.richfaces.integrationTest.extendedDataTable.DraggingTestCase" />
</classes>
</test>
-
+
<test
name="org.jboss.richfaces.integrationTest.extendedDataTable.FilteringTestCase">
<classes>
@@ -235,7 +238,7 @@
name="org.jboss.richfaces.integrationTest.extendedDataTable.FilteringTestCase" />
</classes>
</test>
-
+
<test
name="org.jboss.richfaces.integrationTest.extendedDataTable.GroupingTestCase">
<classes>
@@ -243,7 +246,7 @@
name="org.jboss.richfaces.integrationTest.extendedDataTable.GroupingTestCase" />
</classes>
</test>
-
+
<test
name="org.jboss.richfaces.integrationTest.extendedDataTable.SelectingTestCase">
<classes>
@@ -251,7 +254,7 @@
name="org.jboss.richfaces.integrationTest.extendedDataTable.SelectingTestCase" />
</classes>
</test>
-
+
<test
name="org.jboss.richfaces.integrationTest.extendedDataTable.SortingTestCase">
<classes>
@@ -343,13 +346,13 @@
</classes>
</test>
-<!-- <test-->
-<!-- name="org.jboss.richfaces.integrationTest.mediaOutput.MediaOutputTestCase">-->
-<!-- <classes>-->
-<!-- <class-->
-<!-- name="org.jboss.richfaces.integrationTest.mediaOutput.MediaOutputTestCase" />-->
-<!-- </classes>-->
-<!-- </test>-->
+ <!--
+ <test
+ name="org.jboss.richfaces.integrationTest.mediaOutput.MediaOutputTestCase">
+ <classes> <class
+ name="org.jboss.richfaces.integrationTest.mediaOutput.MediaOutputTestCase"
+ /> </classes> </test>
+ -->
<test
name="org.jboss.richfaces.integrationTest.modalPanel.ModalPanelTestCase">
@@ -375,11 +378,13 @@
</classes>
</test>
-<!-- <test name="org.jboss.richfaces.integrationTest.paint2d.Paint2DTestCase">-->
-<!-- <classes>-->
-<!-- <class name="org.jboss.richfaces.integrationTest.paint2d.Paint2DTestCase" />-->
-<!-- </classes>-->
-<!-- </test>-->
+ <!--
+ <test
+ name="org.jboss.richfaces.integrationTest.paint2d.Paint2DTestCase">
+ <classes> <class
+ name="org.jboss.richfaces.integrationTest.paint2d.Paint2DTestCase" />
+ </classes> </test>
+ -->
<test
name="org.jboss.richfaces.integrationTest.panel.PanelCustomizationTestCase">
@@ -488,6 +493,14 @@
</classes>
</test>
+ <test
+ name="org.jboss.richfaces.integrationTest.stateManager.StateManagerTestCase">
+ <classes>
+ <class
+ name="org.jboss.richfaces.integrationTest.stateManager.StateManagerTestCase" />
+ </classes>
+ </test>
+
<!-- <test name="org.jboss.richfaces.integrationTest.status.StatusTestCase">-->
<!-- <classes>-->
<!-- <class name="org.jboss.richfaces.integrationTest.status.StatusTestCase" />-->
@@ -507,7 +520,7 @@
name="org.jboss.richfaces.integrationTest.suggestionBox.SuggestionBoxTestCase" />
</classes>
</test>
-
+
<test
name="org.jboss.richfaces.integrationTest.tableFiltering.TableFilteringTestCase">
<classes>
Modified: branches/sandbox/rf-demo-ftest-iexplore/src/test/resources/user-extensions/rfqa-extensions.js
===================================================================
--- branches/sandbox/rf-demo-ftest-iexplore/src/test/resources/user-extensions/rfqa-extensions.js 2010-01-13 01:02:45 UTC (rev 16272)
+++ branches/sandbox/rf-demo-ftest-iexplore/src/test/resources/user-extensions/rfqa-extensions.js 2010-01-13 10:18:04 UTC (rev 16273)
@@ -92,4 +92,8 @@
var inDocument = this.browserbot.getDocument();
var found = $(inDocument).find(jquery);
return found.length;
-}
\ No newline at end of file
+}
+
+var jqFind = function(selector) {
+ return $(selenium.browserbot.getCurrentWindow().document).find(selector);
+}
14 years, 3 months
JBoss Rich Faces SVN: r16272 - in root: cdk/trunk/plugins/generator/src/main/java/org/richfaces/cdk/apt and 4 other directories.
by richfaces-svn-commits@lists.jboss.org
Author: alexsmirnov
Date: 2010-01-12 20:02:45 -0500 (Tue, 12 Jan 2010)
New Revision: 16272
Added:
root/DEADJOE
root/examples-sandbox/trunk/components/tables/src/main/webapp/WEB-INF/lib/
root/framework/trunk/impl/src/main/java/META-INF/
root/framework/trunk/impl/src/main/java/META-INF/MANIFEST.MF
Modified:
root/cdk/trunk/plugins/generator/src/main/java/org/richfaces/cdk/apt/BehaviorProcessor.java
root/cdk/trunk/plugins/generator/src/main/java/org/richfaces/cdk/apt/CdkProcessor.java
root/cdk/trunk/plugins/generator/src/main/java/org/richfaces/cdk/apt/ConverterProcessor.java
root/cdk/trunk/plugins/generator/src/main/java/org/richfaces/cdk/apt/RendererProcessor.java
root/cdk/trunk/plugins/generator/src/main/java/org/richfaces/cdk/xmlconfig/model/ConverterBean.java
Log:
Restore APT tests, fix checkstyle errors.
Added: root/DEADJOE
===================================================================
--- root/DEADJOE (rev 0)
+++ root/DEADJOE 2010-01-13 01:02:45 UTC (rev 16272)
@@ -0,0 +1,71 @@
+
+*** These modified files were found in JOE when it aborted on Mon Aug 3 18:27:46 2009
+*** JOE was aborted by UNIX signal 1
+
+*** File '/home/asmirnov/.zshrc'
+#
+# .zshrc is sourced in interactive shells.
+# It should contain commands to set up aliases,
+# functions, options, key bindings, etc.
+#
+
+autoload -U compinit
+compinit
+
+#allow tab completion in the middle of a word
+setopt COMPLETE_IN_WORD
+
+## keep background processes at full speed
+#setopt NOBGNICE
+## restart running processes on exit
+#setopt HUP
+
+## history
+#setopt APPEND_HISTORY
+## for sharing history between zsh processes
+setopt INC_APPEND_HISTORY
+setopt SHARE_HISTORY
+
+## never ever beep ever
+setopt NO_BEEP
+
+## automatically decide when to page a list of completions
+#LISTMAX=0
+
+## disable mail checking
+MAILCHECK=0
+
+autoload -U colors
+colors
+
+alias -g rf4=~/work/jsf/jsf2.0-workspace/root
+alias -g rf=~/work/richfaces/richfaces
+alias -g jfx=~/work/JavaFX
+*** File '(Unnamed)'
+clean install
+(arg|ARG)/:arg:
+
+*** File '(Unnamed)'
+deploy
+docs
+port
+portlet
+Collections.<
+emptyList
+jquery
+firefox
+arg/:arg:
+java.net
+
+*** File '(Unnamed)'
+pom.xml
+pom.xml
+pom.xml
+pom.xml
+mock/pom.xml
+mock/pom.xml
+pom.xml
+stage/pom.xml
+/home/asmirnov/.m2t/settings.xml
+pom.xml
+/home/asmirnov/.zshrc
Modified: root/cdk/trunk/plugins/generator/src/main/java/org/richfaces/cdk/apt/BehaviorProcessor.java
===================================================================
--- root/cdk/trunk/plugins/generator/src/main/java/org/richfaces/cdk/apt/BehaviorProcessor.java 2010-01-13 00:13:03 UTC (rev 16271)
+++ root/cdk/trunk/plugins/generator/src/main/java/org/richfaces/cdk/apt/BehaviorProcessor.java 2010-01-13 01:02:45 UTC (rev 16272)
@@ -27,7 +27,6 @@
import javax.lang.model.element.TypeElement;
-import org.richfaces.cdk.CdkContext;
import org.richfaces.cdk.CdkProcessingException;
import org.richfaces.cdk.annotations.Behavior;
Modified: root/cdk/trunk/plugins/generator/src/main/java/org/richfaces/cdk/apt/CdkProcessor.java
===================================================================
--- root/cdk/trunk/plugins/generator/src/main/java/org/richfaces/cdk/apt/CdkProcessor.java 2010-01-13 00:13:03 UTC (rev 16271)
+++ root/cdk/trunk/plugins/generator/src/main/java/org/richfaces/cdk/apt/CdkProcessor.java 2010-01-13 01:02:45 UTC (rev 16272)
@@ -23,28 +23,24 @@
package org.richfaces.cdk.apt;
-import com.google.common.collect.ImmutableList;
+import java.util.Collections;
+import java.util.Set;
+
+import javax.annotation.processing.AbstractProcessor;
+import javax.annotation.processing.RoundEnvironment;
+import javax.lang.model.SourceVersion;
+import javax.lang.model.element.TypeElement;
+
import org.richfaces.cdk.CdkContext;
-import org.richfaces.cdk.CdkContext.OutputType;
import org.richfaces.cdk.CdkException;
import org.richfaces.cdk.CdkProcessingException;
import org.richfaces.cdk.CdkWorker;
import org.richfaces.cdk.ModelValidator;
import org.richfaces.cdk.StandardOutputs;
import org.richfaces.cdk.StandardSources;
-import org.richfaces.cdk.annotations.Behavior;
-import org.richfaces.cdk.annotations.Component;
-import org.richfaces.cdk.annotations.Converter;
-import org.richfaces.cdk.util.Pair;
+import org.richfaces.cdk.CdkContext.OutputType;
-import javax.annotation.processing.AbstractProcessor;
-import javax.annotation.processing.RoundEnvironment;
-import javax.faces.component.FacesComponent;
-import javax.lang.model.SourceVersion;
-import javax.lang.model.element.TypeElement;
-import java.lang.annotation.Annotation;
-import java.util.Collections;
-import java.util.Set;
+import com.google.common.collect.ImmutableList;
/**
* <p class="changed_added_4_0">
Modified: root/cdk/trunk/plugins/generator/src/main/java/org/richfaces/cdk/apt/ConverterProcessor.java
===================================================================
--- root/cdk/trunk/plugins/generator/src/main/java/org/richfaces/cdk/apt/ConverterProcessor.java 2010-01-13 00:13:03 UTC (rev 16271)
+++ root/cdk/trunk/plugins/generator/src/main/java/org/richfaces/cdk/apt/ConverterProcessor.java 2010-01-13 01:02:45 UTC (rev 16272)
@@ -23,16 +23,13 @@
import java.lang.annotation.Annotation;
-import org.richfaces.cdk.CdkContext;
+import javax.annotation.processing.SupportedAnnotationTypes;
+import javax.lang.model.element.TypeElement;
+
import org.richfaces.cdk.CdkProcessingException;
import org.richfaces.cdk.annotations.Converter;
-import org.richfaces.cdk.annotations.DisplayName;
-import org.richfaces.cdk.annotations.Icon;
import org.richfaces.cdk.model.ConverterModel;
-import javax.annotation.processing.SupportedAnnotationTypes;
-import javax.lang.model.element.TypeElement;
-
/**
* @author akolonitsky
* @since Jan 4, 2010
Modified: root/cdk/trunk/plugins/generator/src/main/java/org/richfaces/cdk/apt/RendererProcessor.java
===================================================================
--- root/cdk/trunk/plugins/generator/src/main/java/org/richfaces/cdk/apt/RendererProcessor.java 2010-01-13 00:13:03 UTC (rev 16271)
+++ root/cdk/trunk/plugins/generator/src/main/java/org/richfaces/cdk/apt/RendererProcessor.java 2010-01-13 01:02:45 UTC (rev 16272)
@@ -21,7 +21,12 @@
package org.richfaces.cdk.apt;
-import org.richfaces.cdk.CdkContext;
+import java.lang.annotation.Annotation;
+import java.util.Map;
+
+import javax.annotation.processing.SupportedAnnotationTypes;
+import javax.lang.model.element.TypeElement;
+
import org.richfaces.cdk.CdkException;
import org.richfaces.cdk.NamingConventions;
import org.richfaces.cdk.annotations.Component;
@@ -31,18 +36,11 @@
import org.richfaces.cdk.annotations.Icon;
import org.richfaces.cdk.annotations.Renderer;
import org.richfaces.cdk.model.ComponentLibrary;
-import org.richfaces.cdk.model.DescriptionGroup;
import org.richfaces.cdk.model.Property;
import org.richfaces.cdk.model.RendererModel;
import org.richfaces.cdk.xmlconfig.CdkEntityResolver;
import org.richfaces.cdk.xmlconfig.FragmentParser;
-import javax.annotation.processing.SupportedAnnotationTypes;
-import javax.lang.model.element.TypeElement;
-
-import java.lang.annotation.Annotation;
-import java.util.Map;
-
/**
* @author akolonitsky
* @since Dec 30, 2009
Modified: root/cdk/trunk/plugins/generator/src/main/java/org/richfaces/cdk/xmlconfig/model/ConverterBean.java
===================================================================
--- root/cdk/trunk/plugins/generator/src/main/java/org/richfaces/cdk/xmlconfig/model/ConverterBean.java 2010-01-13 00:13:03 UTC (rev 16271)
+++ root/cdk/trunk/plugins/generator/src/main/java/org/richfaces/cdk/xmlconfig/model/ConverterBean.java 2010-01-13 01:02:45 UTC (rev 16272)
@@ -21,17 +21,27 @@
package org.richfaces.cdk.xmlconfig.model;
+import java.util.List;
+
import org.richfaces.cdk.model.ComponentLibrary;
import org.richfaces.cdk.model.ConfigExtension;
+import com.google.common.collect.Lists;
+
+import javax.xml.bind.annotation.XmlElements;
import javax.xml.bind.annotation.XmlType;
import javax.xml.bind.annotation.XmlElement;
+import javax.xml.bind.annotation.adapters.XmlJavaTypeAdapter;
/**
* @author akolonitsky
* @since Jan 6, 2010
*/
-public class ConverterBean extends ExtensibleBean<ConfigExtension> {
+@XmlType(name = "faces-config-converterType", namespace = ComponentLibrary.FACES_CONFIG_NAMESPACE,
+ propOrder={"converterId", "converterForClass", "converterClass",
+ "attributes", "extension"})
+(a)XmlJavaTypeAdapter(ConverterAdapter.class)
+public class ConverterBean extends ExtensibleBean<ConverterBean.ConverterExtension> {
private String converterId;
@@ -39,6 +49,8 @@
private String converterClass;
+ private List<PropertyBase> attributes = Lists.newArrayList();
+
@XmlElement(name = "converter-id", namespace = ComponentLibrary.FACES_CONFIG_NAMESPACE)
public String getConverterId() {
return converterId;
@@ -68,12 +80,45 @@
@XmlElement(name = "converter-extension", namespace = ComponentLibrary.FACES_CONFIG_NAMESPACE)
@Override
- public ConfigExtension getExtension() {
+ public ConverterExtension getExtension() {
return super.getExtension();
}
+ /**
+ * <p class="changed_added_4_0"></p>
+ *
+ * @return the attributes
+ */
+ @XmlElements({@XmlElement(
+ name = "property",
+ namespace = ComponentLibrary.FACES_CONFIG_NAMESPACE,
+ type = PropertyBean.class
+ ), @XmlElement(
+ name = "attribute",
+ namespace = ComponentLibrary.FACES_CONFIG_NAMESPACE,
+ type = AttributeBean.class
+ )})
+
+ public List<PropertyBase> getAttributes() {
+ return attributes;
+ }
+
+ /**
+ * <p class="changed_added_4_0"></p>
+ *
+ * @param attributes the attributes to set
+ */
+ public void setAttributes(List<PropertyBase> property) {
+ this.attributes = property;
+ }
+
@Override
- public void setExtension(ConfigExtension extension) {
+ public void setExtension(ConverterExtension extension) {
super.setExtension(extension);
}
+
+ public static class ConverterExtension extends ConfigExtension {
+
+ }
+
}
Added: root/framework/trunk/impl/src/main/java/META-INF/MANIFEST.MF
===================================================================
--- root/framework/trunk/impl/src/main/java/META-INF/MANIFEST.MF (rev 0)
+++ root/framework/trunk/impl/src/main/java/META-INF/MANIFEST.MF 2010-01-13 01:02:45 UTC (rev 16272)
@@ -0,0 +1,3 @@
+Manifest-Version: 1.0
+Class-Path:
+
Property changes on: root/framework/trunk/impl/src/main/java/META-INF/MANIFEST.MF
___________________________________________________________________
Name: svn:mime-type
+ text/plain
14 years, 3 months
JBoss Rich Faces SVN: r16271 - in root/cdk/trunk/plugins/generator/src: main/java/org/richfaces/cdk/xmlconfig and 1 other directories.
by richfaces-svn-commits@lists.jboss.org
Author: alexsmirnov
Date: 2010-01-12 19:13:03 -0500 (Tue, 12 Jan 2010)
New Revision: 16271
Modified:
root/cdk/trunk/plugins/generator/src/main/java/org/richfaces/cdk/templatecompiler/RendererTemplateParser.java
root/cdk/trunk/plugins/generator/src/main/java/org/richfaces/cdk/xmlconfig/FacesConfigParser.java
root/cdk/trunk/plugins/generator/src/test/java/org/richfaces/cdk/apt/ComponentProcessorTest.java
Log:
Fix component processor test.
Modified: root/cdk/trunk/plugins/generator/src/main/java/org/richfaces/cdk/templatecompiler/RendererTemplateParser.java
===================================================================
--- root/cdk/trunk/plugins/generator/src/main/java/org/richfaces/cdk/templatecompiler/RendererTemplateParser.java 2010-01-13 00:11:42 UTC (rev 16270)
+++ root/cdk/trunk/plugins/generator/src/main/java/org/richfaces/cdk/templatecompiler/RendererTemplateParser.java 2010-01-13 00:13:03 UTC (rev 16271)
@@ -38,8 +38,9 @@
import org.richfaces.cdk.xmlconfig.JAXBBinding;
/**
- * <p class="changed_added_4_0"></p>
- *
+ * <p class="changed_added_4_0">
+ * </p>
+ *
* @author asmirnov(a)exadel.com
*/
public class RendererTemplateParser implements ModelBuilder {
@@ -47,34 +48,39 @@
private JAXBBinding jaxbBinding;
/*
- * (non-Javadoc)
+ * (non-Javadoc)
+ *
* @see org.richfaces.cdk.ModelBuilder#build()
*/
@Override
public void build() throws CdkException {
ComponentLibrary library = context.getLibrary();
- for (File file : getContext().getSources(StandardSources.RENDERER_TEMPLATES)) {
- Template template = parseTemplate(file);
- CompositeInterface compositeInterface = template.getInterface();
- // TODO - infer values ?
- RenderKitModel renderKit = library.addRenderKit(compositeInterface.getRenderKitId());
- RendererModel renderer = new RendererModel(new RendererModel.Type(compositeInterface.getRendererType()));
- renderKit.getRenderers().add(renderer);
- String componentType = compositeInterface.getComponentType();
+ Iterable<File> sources = getContext().getSources(StandardSources.RENDERER_TEMPLATES);
+ if (null != sources) {
+ for (File file : sources) {
+ Template template = parseTemplate(file);
+ CompositeInterface compositeInterface = template.getInterface();
+ // TODO - infer values ?
+ RenderKitModel renderKit = library.addRenderKit(compositeInterface.getRenderKitId());
+ RendererModel renderer =
+ new RendererModel(new RendererModel.Type(compositeInterface.getRendererType()));
+ renderKit.getRenderers().add(renderer);
+ String componentType = compositeInterface.getComponentType();
- // component.getRenderers().add(renderer);
+ // component.getRenderers().add(renderer);
- String family = compositeInterface.getComponentFamily();
+ String family = compositeInterface.getComponentFamily();
- if (null != family) {
- renderer.setFamily(family);
+ if (null != family) {
+ renderer.setFamily(family);
+ }
+
+ renderer.setRendererClass(new ClassDescription(compositeInterface.getJavaClass()));
+ renderer.setTemplate(template);
}
- renderer.setRendererClass(new ClassDescription(compositeInterface.getJavaClass()));
- renderer.setTemplate(template);
}
-
}
protected Template parseTemplate(File file) throws CdkException {
@@ -82,7 +88,8 @@
}
/*
- * (non-Javadoc)
+ * (non-Javadoc)
+ *
* @see org.richfaces.cdk.ModelBuilder#init(org.richfaces.cdk.CdkContext)
*/
@Override
Modified: root/cdk/trunk/plugins/generator/src/main/java/org/richfaces/cdk/xmlconfig/FacesConfigParser.java
===================================================================
--- root/cdk/trunk/plugins/generator/src/main/java/org/richfaces/cdk/xmlconfig/FacesConfigParser.java 2010-01-13 00:11:42 UTC (rev 16270)
+++ root/cdk/trunk/plugins/generator/src/main/java/org/richfaces/cdk/xmlconfig/FacesConfigParser.java 2010-01-13 00:13:03 UTC (rev 16271)
@@ -21,8 +21,6 @@
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
*/
-
-
package org.richfaces.cdk.xmlconfig;
import org.richfaces.cdk.CdkContext;
@@ -36,9 +34,11 @@
import java.io.File;
/**
- * <p class="changed_added_4_0"></p>
+ * <p class="changed_added_4_0">
+ * </p>
+ *
* @author asmirnov(a)exadel.com
- *
+ *
*/
public class FacesConfigParser implements ModelBuilder {
@@ -48,7 +48,9 @@
private JAXBBinding jaxbBinding;
/**
- * <p class="changed_added_4_0"></p>
+ * <p class="changed_added_4_0">
+ * </p>
+ *
* @return the context
*/
public CdkContext getContext() {
@@ -56,29 +58,33 @@
}
/*
- * (non-Javadoc)
+ * (non-Javadoc)
+ *
* @see org.richfaces.cdk.ModelBuilder#build()
*/
@Override
public void build() throws CdkException {
ComponentLibrary library = context.getLibrary();
- for (File file : context.getSources(StandardSources.FACES_CONFIGS)) {
- FacesConfigBean unmarshal = unmarshalFacesConfig(file);
- if(null != unmarshal){
- ComponentLibrary facesConfig = ADAPTER.unmarshal(unmarshal);
- library.getComponents().addAll(facesConfig.getComponents());
- library.getRenderKits().putAll(facesConfig.getRenderKits());
- library.getConverters().addAll(facesConfig.getConverters());
- // TODO - merge changes into library.
- // library.getRenderers().addAll(unmarshal.getRenderers());
- // library.getValidators().addAll(unmarshal.getValidators);
- // library.getConverters().addAll(unmarshal.getConverters());
- // library.getBehaviors().addAll(unmarshal.getBehaviors());
- // library.setExtensions(unmarshal.getExtensions());
+ Iterable<File> sources = context.getSources(StandardSources.FACES_CONFIGS);
+ if (null != sources) {
+ for (File file : sources) {
+ FacesConfigBean unmarshal = unmarshalFacesConfig(file);
+ if (null != unmarshal) {
+ ComponentLibrary facesConfig = ADAPTER.unmarshal(unmarshal);
+ library.getComponents().addAll(facesConfig.getComponents());
+ library.getRenderKits().putAll(facesConfig.getRenderKits());
+ library.getConverters().addAll(facesConfig.getConverters());
+ // TODO - merge changes into library.
+ // library.getRenderers().addAll(unmarshal.getRenderers());
+ // library.getValidators().addAll(unmarshal.getValidators);
+ // library.getConverters().addAll(unmarshal.getConverters());
+ // library.getBehaviors().addAll(unmarshal.getBehaviors());
+ // library.setExtensions(unmarshal.getExtensions());
+ }
}
+
}
-
}
protected FacesConfigBean unmarshalFacesConfig(File file) throws CdkException {
@@ -86,7 +92,8 @@
}
/*
- * (non-Javadoc)
+ * (non-Javadoc)
+ *
* @see org.richfaces.cdk.ModelBuilder#init(org.richfaces.cdk.CdkContext)
*/
@Override
Modified: root/cdk/trunk/plugins/generator/src/test/java/org/richfaces/cdk/apt/ComponentProcessorTest.java
===================================================================
--- root/cdk/trunk/plugins/generator/src/test/java/org/richfaces/cdk/apt/ComponentProcessorTest.java 2010-01-13 00:11:42 UTC (rev 16270)
+++ root/cdk/trunk/plugins/generator/src/test/java/org/richfaces/cdk/apt/ComponentProcessorTest.java 2010-01-13 00:13:03 UTC (rev 16271)
@@ -29,6 +29,7 @@
import static org.junit.Assert.*;
import java.util.Collection;
+import java.util.Collections;
import java.util.Map;
import javax.el.ELContext;
@@ -38,7 +39,11 @@
import org.junit.Test;
import org.richfaces.cdk.CdkClassLoader;
import org.richfaces.cdk.CdkContext;
+import org.richfaces.cdk.CdkContextBase;
+import org.richfaces.cdk.CdkException;
+import org.richfaces.cdk.CdkProcessingException;
import org.richfaces.cdk.CdkTestBase;
+import org.richfaces.cdk.ModelValidator;
import org.richfaces.cdk.NamingConventions;
import org.richfaces.cdk.RichFacesConventions;
import org.richfaces.cdk.StandardSources;
@@ -71,7 +76,6 @@
* @throws Exception
*/
@Test
- @Ignore
public void testProcess() throws Exception {
// Prepare Mock compilation context.
@@ -82,7 +86,6 @@
compiler.init(cdkContext);
processor.init(cdkContext);
compiler.process(ImmutableList.of(getJavaFile(COMPONENT_CLASS_JAVA)), processor);
- verify(cdkContext);
ComponentLibrary library = cdkContext.getLibrary();
Collection<ComponentModel> components = library.getComponents();
@@ -92,7 +95,7 @@
ComponentModel component = Iterables.get(components, 0);
Map<String, Property> attributes = component.getAttributes();
- assertEquals(17, attributes.size());
+ assertEquals(3, attributes.size());
}
/**
@@ -103,7 +106,6 @@
* @throws Exception
*/
@Test
- @Ignore
public void testProcessFacesComponent() throws Exception {
// Prepare Mock compilation context.
@@ -114,7 +116,6 @@
compiler.init(cdkContext);
processor.init(cdkContext);
compiler.process(ImmutableList.of(getJavaFile(FACES_COMPONENT_CLASS_JAVA)), processor);
- verify(cdkContext);
ComponentLibrary library = cdkContext.getLibrary();
Collection<ComponentModel> components = library.getComponents();
@@ -124,35 +125,28 @@
ComponentModel component = Iterables.get(components, 0);
Map<String, Property> attributes = component.getAttributes();
- assertEquals(15, attributes.size());
+ assertEquals(0, attributes.size());
}
private CdkContext createMockContext() throws Exception {
- CdkContext cdkContext = createMock(CdkContext.class);
-
- expect(cdkContext.getSourceFolders(StandardSources.JAVA_SOURCES)).andStubReturn(testSourceDirectory);
- expect(cdkContext.getOutputFolder((org.richfaces.cdk.CdkContext.OutputType) anyObject())).andStubReturn(null);
- expect(cdkContext.getLoader()).andStubReturn(createClassLoader());
- expect(cdkContext.getLibrary()).andStubReturn(new ComponentLibrary());
-
+ CdkContextBase baseContext = new CdkContextBase(createClassLoader());
+ baseContext.setSourceFolders(StandardSources.JAVA_SOURCES, testSourceDirectory);
RichFacesConventions richFacesConventions = new RichFacesConventions();
+ baseContext.setWorker(NamingConventions.class, richFacesConventions);
+ baseContext.setWorker(ModelValidator.class, new ModelValidator() {
+
+ @Override
+ public void init(CdkContext context) {
+
+ }
+
+ @Override
+ public void verify(ComponentLibrary library) throws CdkException {
+ }
+ });
+ baseContext.sendError(new CdkProcessingException());
- expect(cdkContext.getWorker(NamingConventions.class)).andStubReturn(richFacesConventions);
-
- FragmentParser fragmentParser = new FragmentParser();
-
- expect(cdkContext.getWorker(FragmentParser.class)).andStubReturn(fragmentParser);
-
- JAXBBinding jaxbBinding = new JAXBBinding();
-
- expect(cdkContext.getWorker(JAXBBinding.class)).andStubReturn(jaxbBinding);
- expect(cdkContext.setWorker(eq(SourceUtils.class), (SourceUtils) anyObject())).andStubReturn(null);
- replay(cdkContext);
- richFacesConventions.init(cdkContext);
- jaxbBinding.init(cdkContext);
- fragmentParser.init(cdkContext);
-
- return cdkContext;
+ return baseContext;
}
protected CdkClassLoader createClassLoader() throws Exception {
14 years, 3 months
JBoss Rich Faces SVN: r16270 - in root/docs/trunk/Component_Reference/en-US: images and 1 other directory.
by richfaces-svn-commits@lists.jboss.org
Author: SeanRogers
Date: 2010-01-12 19:11:42 -0500 (Tue, 12 Jan 2010)
New Revision: 16270
Added:
root/docs/trunk/Component_Reference/en-US/chap-Component_Reference-Selection_and_ordering.xml
root/docs/trunk/Component_Reference/en-US/images/figu-Component_Reference-richajaxValidator-richajaxValidator_example_result.png
root/docs/trunk/Component_Reference/en-US/images/figu-Component_Reference-richbeanValidator-richbeanValidator_example_result.png
root/docs/trunk/Component_Reference/en-US/images/figu-Component_Reference-richgraphValidator-Result_from_using_the_value_attribute.png
root/docs/trunk/Component_Reference/en-US/images/figu-Component_Reference-richgraphValidator-richgraphValidator_example_result.png
Modified:
root/docs/trunk/Component_Reference/en-US/Author_Group.xml
root/docs/trunk/Component_Reference/en-US/chap-Component_Reference-Common_Ajax_attributes.xml
root/docs/trunk/Component_Reference/en-US/chap-Component_Reference-Trees.xml
root/docs/trunk/Component_Reference/en-US/chap-Component_Reference-Validation.xml
Log:
Updating Validation. Added images. Added Selection and ordering chapter. Added Exadel authors.
Modified: root/docs/trunk/Component_Reference/en-US/Author_Group.xml
===================================================================
--- root/docs/trunk/Component_Reference/en-US/Author_Group.xml 2010-01-12 18:11:20 UTC (rev 16269)
+++ root/docs/trunk/Component_Reference/en-US/Author_Group.xml 2010-01-13 00:11:42 UTC (rev 16270)
@@ -5,11 +5,72 @@
<author>
<firstname>Sean</firstname>
<surname>Rogers</surname>
+ <contrib>Documentation lead for 4.0</contrib>
<affiliation>
<orgname>Red Hat</orgname>
<orgdiv>Engineering Content Services</orgdiv>
</affiliation>
<email>serogers(a)redhat.com</email>
</author>
+ <author>
+ <firstname>Svetlana</firstname>
+ <surname>Mukhina</surname>
+ <contrib>Documentation lead for 3.3</contrib>
+ <affiliation>
+ <orgname>Exadel</orgname>
+ <orgdiv>Documentation</orgdiv>
+ </affiliation>
+ <email>smukhina(a)exadel.com</email>
+ </author>
+ <author>
+ <firstname>Anastasiya</firstname>
+ <surname>Bogachuk</surname>
+ <contrib>Documentation for 3.3</contrib>
+ <affiliation>
+ <orgname>Exadel</orgname>
+ <orgdiv>Documentation</orgdiv>
+ </affiliation>
+ <email>abogachuk(a)exadel.com</email>
+ </author>
+ <author>
+ <firstname>Gleb</firstname>
+ <surname>Galkin</surname>
+ <contrib>Documentation for 3.3</contrib>
+ <affiliation>
+ <orgname>Exadel</orgname>
+ <orgdiv>Documentation</orgdiv>
+ </affiliation>
+ <email>ggalkin(a)exadel.com</email>
+ </author>
+ <author>
+ <firstname>Mikhail</firstname>
+ <surname>Sorokin</surname>
+ <contrib>Documentation for 3.3</contrib>
+ <affiliation>
+ <orgname>Exadel</orgname>
+ <orgdiv>Documentation</orgdiv>
+ </affiliation>
+ <email>msorokin(a)exadel.com</email>
+ </author>
+ <author>
+ <firstname>Alexander</firstname>
+ <surname>Tsebro</surname>
+ <contrib>Documentation for 3.3</contrib>
+ <affiliation>
+ <orgname>Exadel</orgname>
+ <orgdiv>Documentation</orgdiv>
+ </affiliation>
+ <email>atsebro(a)exadel.com</email>
+ </author>
+ <author>
+ <firstname>Olga</firstname>
+ <surname>Chikvina</surname>
+ <contrib>Documentation for 3.3</contrib>
+ <affiliation>
+ <orgname>Exadel</orgname>
+ <orgdiv>Documentation</orgdiv>
+ </affiliation>
+ <email>ochikvina(a)exadel.com</email>
+ </author>
</authorgroup>
Modified: root/docs/trunk/Component_Reference/en-US/chap-Component_Reference-Common_Ajax_attributes.xml
===================================================================
--- root/docs/trunk/Component_Reference/en-US/chap-Component_Reference-Common_Ajax_attributes.xml 2010-01-12 18:11:20 UTC (rev 16269)
+++ root/docs/trunk/Component_Reference/en-US/chap-Component_Reference-Common_Ajax_attributes.xml 2010-01-13 00:11:42 UTC (rev 16270)
@@ -51,7 +51,7 @@
</section>
<section id="sect-Component_Reference-Rendering-ajaxRendered">
- <title>ajaxRendered</title>
+ <title><varname>ajaxRendered</varname></title>
<para>
A component with <code>ajaxRendered="true"</code> will be re-rendered with <emphasis>every</emphasis> Ajax request, even when not referenced by the requesting component's <varname>render</varname> attribute. This can be useful for updating a status display or error message without explicitly requesting it.
</para>
@@ -61,7 +61,7 @@
</section>
<section id="sect-Component_Reference-Rendering-limitRender">
- <title>limitRender</title>
+ <title><varname>limitRender</varname></title>
<para>
A component with <code>limitRender="true"</code> specified will <emphasis>not</emphasis> cause components with <code>ajaxRendered="true"</code> to re-render, and only those components listed in the <varname>render</varname> attribute will be updated. This essentially overrides the <varname>ajaxRendered</varname> attribute in other components.
</para>
@@ -93,7 +93,7 @@
<section id="sect-Component_Reference-Common_Ajax_attributes-Queuing_and_traffic_control">
<title>Queuing and traffic control</title>
<section id="sect-Component_Reference-Queuing_and_traffic_control-queue">
- <title>queue</title>
+ <title><varname>queue</varname></title>
<para>
The <varname>queue</varname> attribute defines the name of the queue that will be used to schedule upcoming Ajax requests. Typically RichFaces does not queue Ajax requests, so if events are produced simultaneously they will arrive at the server simultaneously. This can potentially lead to unpredictable results when the responses are returned. The <varname>queue</varname> attribute ensures that the requests are responded to in a set order.
</para>
@@ -103,14 +103,14 @@
</section>
<section id="sect-Component_Reference-Queuing_and_traffic_control-requestDelay">
- <title>requestDelay</title>
+ <title><varname>requestDelay</varname></title>
<para>
The <varname>requestDelay</varname> attribute specifies an amount of time in milliseconds for the request to wait in the queue before being sent to the server. If a similar request is added to the queue before the delay is over, the original request is removed from the queue and not sent.
</para>
</section>
<section id="sect-Component_Reference-Queuing_and_traffic_control-ignoreDupResponses">
- <title>ignoreDupResponses</title>
+ <title><varname>ignoreDupResponses</varname></title>
<para>
When set to <literal>true</literal>, the <varname>ignoreDupResponses</varname> attribute causes responses from the server for the request to be ignored if there is another similar request in the queue. This avoids unnecessary updates on the client when another update is expected. The request is still processed on the server, but if another similar request has been queued then no updates are made on the client.
</para>
@@ -124,21 +124,21 @@
RichFaces uses a form-based approach for sending Ajax requests. As such, each time a request is sent the data from the requesting component's parent <acronym>JSF</acronym> form is submitted along with the <acronym>XMLHTTPRequest</acronym> object. The form data contains values from the input element and auxiliary information such as state-saving data.
</para>
<section id="sect-Component_Reference-Data_processing-process">
- <title>process</title>
+ <title><varname>process</varname></title>
<para>
The <varname>process</varname> attribute allows <acronym>JSF</acronym> processing to be limited to defined components. To only process the requesting component, <code>process="@this"</code> can be used.
</para>
</section>
<section id="sect-Component_Reference-Data_processing-immediate">
- <title>immediate</title>
+ <title><varname>immediate</varname></title>
<para>
If the <varname>immediate</varname> attribute is set to <literal>true</literal>, the default ActionListener is executed immediately during the Apply Request Values phase of the request processing lifecycle, rather than waitingfor the Invoke Application phase. This allows some data model values to be updated regardless of whether the Validation phase is successful or not.
</para>
</section>
<section id="sect-Component_Reference-Data_processing-bypassUpdates">
- <title>bypassUpdates</title>
+ <title><varname>bypassUpdates</varname></title>
<para>
If the <varname>bypassUpdates</varname> attribute is set to <literal>true</literal>, the Update Model phase of the request processing lifecycle is bypassed. This is useful if user input needs to be validated but the model does not need to be updated.
</para>
@@ -152,7 +152,7 @@
The <varname>action</varname> and <varname>actionListener</varname> attributes can be used to invoke action methods and define action events.
</para>
<section id="sect-Component_Reference-Action_and_navigation-action">
- <title>action</title>
+ <title><varname>action</varname></title>
<para>
The <varname>action</varname> attribute is a method binding that points to the application action to be invoked. The method can be activated during the Apply Request Values phase or the Invoke Application phase of the request processing lifecycle.
</para>
@@ -162,7 +162,7 @@
</section>
<section id="sect-Component_Reference-Action_and_navigation-actionListener">
- <title>actionListener</title>
+ <title><varname>actionListener</varname></title>
<para>
The <varname>actionListener</varname> attribute is a method binding for <classname>ActionEvent</classname> methods with a return type of <literal>void</literal>.
</para>
@@ -176,49 +176,49 @@
RichFaces allows for Ajax-enabled <acronym>JSF</acronym> applications to be developed without using any additional JavaScript code. However it is still possible to invoke custom JavaScript code through Ajax events.
</para>
<section id="sect-Component_Reference-Events_and_JavaScript_interactions-onsubmit">
- <title>onsubmit</title>
+ <title><varname>onsubmit</varname></title>
<para>
The <varname>onsubmit</varname> attribute will invoke the JavaScript code before the Ajax request is sent. The request is canceled if the JavaScript code defined for <varname>onsubmit</varname> returns <literal>false</literal>.
</para>
</section>
<section id="sect-Component_Reference-Events_and_JavaScript_interactions-onclick">
- <title>onclick</title>
+ <title><varname>onclick</varname></title>
<para>
The <varname>onclick</varname> attribute functions similarly to the <varname>onsubmit</varname> attribute for those components that can be clicked, such as <sgmltag><a4j:commandButton></sgmltag> and <sgmltag><a4j:commandLink></sgmltag>. It invokes the defined JavaScript before the Ajax request, and the request will be canceled if the defined code returns <literal>false</literal>.
</para>
</section>
<section id="sect-Component_Reference-Events_and_JavaScript_interactions-oncomplete">
- <title>oncomplete</title>
+ <title><varname>oncomplete</varname></title>
<para>
The <varname>oncomplete</varname> attribute invokes the JavaScript code after the Ajax response has been returned and the <acronym>DOM</acronym> tree of the browser has been updated. The code is registered for further invocation of the <acronym>XMLHTTP</acronym> request object before an Ajax request is sent. As such, using <acronym>JSF</acronym> Expression Language (<acronym>EL</acronym>) value binding means the code will not be changed during processing of the request on the server. Additionally the <varname>oncomplete</varname> attribute cannot use the <literal>this</literal> keyword as it will not point to the component from which the Ajax request was initiated.
</para>
</section>
<section id="sect-Component_Reference-Events_and_JavaScript_interactions-onbegin">
- <title>onbegin</title>
+ <title><varname>onbegin</varname></title>
<para>
Incomplete
</para>
</section>
<section id="sect-Component_Reference-Events_and_JavaScript_interactions-onsuccess">
- <title>onsuccess</title>
+ <title><varname>onsuccess</varname></title>
<para>
Incomplete
</para>
</section>
<section id="sect-Component_Reference-Events_and_JavaScript_interactions-onerror">
- <title>onerror</title>
+ <title><varname>onerror</varname></title>
<para>
Incomplete
</para>
</section>
<section id="sect-Component_Reference-Events_and_JavaScript_interactions-data">
- <title>data</title>
+ <title><varname>data</varname></title>
<para>
The <varname>data</varname> attribute allows the use of additional data during an Ajax call. <acronym>JSF</acronym> Expression Language (<acronym>EL</acronym>) can be used to reference the property of the managed bean, and its value will be serialized in JavaScript Object Notation (<acronym>JSON</acronym>) and returned to the client side. The property can then be referenced through the <varname>data</varname> variable in the event attribute definitions. Both primitive types and complex types such as arrays and collections can be serialized and used with <varname>data</varname>.
</para>
Added: root/docs/trunk/Component_Reference/en-US/chap-Component_Reference-Selection_and_ordering.xml
===================================================================
--- root/docs/trunk/Component_Reference/en-US/chap-Component_Reference-Selection_and_ordering.xml (rev 0)
+++ root/docs/trunk/Component_Reference/en-US/chap-Component_Reference-Selection_and_ordering.xml 2010-01-13 00:11:42 UTC (rev 16270)
@@ -0,0 +1,32 @@
+<?xml version='1.0' encoding='utf-8' ?>
+<!DOCTYPE chapter PUBLIC "-//OASIS//DTD DocBook XML V4.5//EN" "http://www.oasis-open.org/docbook/xml/4.5/docbookx.dtd" [
+]>
+<chapter id="chap-Component_Reference-Selection_and_ordering">
+ <title>Selection and ordering</title>
+ <para>
+ Incomplete
+ </para>
+
+ <section id="sect-Component_Reference-Trees-richlistShuttle">
+ <title>rich:listShuttle</title>
+ <para>
+ Incomplete
+ </para>
+ </section>
+
+ <section id="sect-Component_Reference-Trees-richorderingList">
+ <title>rich:orderingList</title>
+ <para>
+ Incomplete
+ </para>
+ </section>
+
+ <section id="sect-Component_Reference-Trees-richpickList">
+ <title>rich:pickList</title>
+ <para>
+ Incomplete
+ </para>
+ </section>
+
+</chapter>
+
Modified: root/docs/trunk/Component_Reference/en-US/chap-Component_Reference-Trees.xml
===================================================================
--- root/docs/trunk/Component_Reference/en-US/chap-Component_Reference-Trees.xml 2010-01-12 18:11:20 UTC (rev 16269)
+++ root/docs/trunk/Component_Reference/en-US/chap-Component_Reference-Trees.xml 2010-01-13 00:11:42 UTC (rev 16270)
@@ -6,48 +6,7 @@
<para>
Incomplete
</para>
- <section id="sect-Component_Reference-Trees-richdataDefinitionList">
- <title>rich:dataDefinitionList</title>
- <para>
- Incomplete
- </para>
- </section>
- <section id="sect-Component_Reference-Trees-richdataList">
- <title>rich:dataList</title>
- <para>
- Incomplete
- </para>
- </section>
-
- <section id="sect-Component_Reference-Trees-richdataOrderedList">
- <title>rich:dataOrderedList</title>
- <para>
- Incomplete
- </para>
- </section>
-
- <section id="sect-Component_Reference-Trees-richlistShuttle">
- <title>rich:listShuttle</title>
- <para>
- Incomplete
- </para>
- </section>
-
- <section id="sect-Component_Reference-Trees-richorderingList">
- <title>rich:orderingList</title>
- <para>
- Incomplete
- </para>
- </section>
-
- <section id="sect-Component_Reference-Trees-richpickList">
- <title>rich:pickList</title>
- <para>
- Incomplete
- </para>
- </section>
-
<section id="sect-Component_Reference-Trees-richchangeExpandListener">
<title>rich:changeExpandListener</title>
<para>
Modified: root/docs/trunk/Component_Reference/en-US/chap-Component_Reference-Validation.xml
===================================================================
--- root/docs/trunk/Component_Reference/en-US/chap-Component_Reference-Validation.xml 2010-01-12 18:11:20 UTC (rev 16269)
+++ root/docs/trunk/Component_Reference/en-US/chap-Component_Reference-Validation.xml 2010-01-13 00:11:42 UTC (rev 16270)
@@ -67,6 +67,21 @@
<programlisting language="Java" role="JAVA">
<xi:include href="extras/exam-Component_Reference-ValidationBean.js" parse="text" xmlns:xi="http://www.w3.org/2001/XInclude" />
</programlisting>
+ <blockquote>
+ <figure id="figu-Component_Reference-richajaxValidator-richajaxValidator_example_result">
+ <title>rich:ajaxValidator example result</title>
+ <mediaobject>
+ <imageobject>
+ <imagedata fileref="images/figu-Component_Reference-richajaxValidator-richajaxValidator_example_result.png" format="PNG" />
+ </imageobject>
+ <textobject>
+ <para>
+ The result of the <sgmltag><rich:ajaxValidator></sgmltag> example: three text entry fields with corresponding validation messages.
+ </para>
+ </textobject>
+ </mediaobject>
+ </figure>
+ </blockquote>
</example>
</section>
@@ -121,6 +136,21 @@
<programlisting language="Java" role="JAVA">
<xi:include href="extras/exam-Component_Reference-ValidationBean.js" parse="text" xmlns:xi="http://www.w3.org/2001/XInclude" />
</programlisting>
+ <blockquote>
+ <figure id="figu-Component_Reference-richbeanValidator-richbeanValidator_example_result">
+ <title>rich:beanValidator example result</title>
+ <mediaobject>
+ <imageobject>
+ <imagedata fileref="images/figu-Component_Reference-richbeanValidator-richbeanValidator_example_result.png" format="PNG" />
+ </imageobject>
+ <textobject>
+ <para>
+ The result of the <sgmltag><rich:beanValidator></sgmltag> example: three text entry fields with corresponding validation messages.
+ </para>
+ </textobject>
+ </mediaobject>
+ </figure>
+ </blockquote>
</example>
</section>
@@ -175,6 +205,21 @@
<programlisting language="Java" role="JAVA">
<xi:include href="extras/exam-Component_Reference-ValidationBean.js" parse="text" xmlns:xi="http://www.w3.org/2001/XInclude" />
</programlisting>
+ <blockquote>
+ <figure id="figu-Component_Reference-richgraphValidator-richgraphValidator_example_result">
+ <title>rich:graphValidator example result</title>
+ <mediaobject>
+ <imageobject>
+ <imagedata fileref="images/figu-Component_Reference-richgraphValidator-richgraphValidator_example_result.png" format="PNG" />
+ </imageobject>
+ <textobject>
+ <para>
+ The result of the <sgmltag><rich:graphValidator></sgmltag> example: three text entry fields with corresponding validation messages.
+ </para>
+ </textobject>
+ </mediaobject>
+ </figure>
+ </blockquote>
</example>
<para>
The optional <varname>value</varname> attribute can be used to define a value bound to the bean. The bean properties are then validated again <emphasis>after</emphasis> the model has been updated.
@@ -185,6 +230,21 @@
<programlisting language="XML" role="XML">
<xi:include href="extras/exam-Component_Reference-richgraphValidator-Using_the_value_attribute.xml_sample" parse="text" xmlns:xi="http://www.w3.org/2001/XInclude" />
</programlisting>
+ <blockquote>
+ <figure id="figu-Component_Reference-richgraphValidator-Result_from_using_the_value_attribute">
+ <title>Result from using the value attribute</title>
+ <mediaobject>
+ <imageobject>
+ <imagedata fileref="images/figu-Component_Reference-richgraphValidator-Result_from_using_the_value_attribute.png" format="PNG" />
+ </imageobject>
+ <textobject>
+ <para>
+ The result from the example of using the <varname>value</varname> attribute with <sgmltag><rich:graphValidator></sgmltag>. The values in the number spinners need to validate before being stored.
+ </para>
+ </textobject>
+ </mediaobject>
+ </figure>
+ </blockquote>
</example>
</section>
Added: root/docs/trunk/Component_Reference/en-US/images/figu-Component_Reference-richajaxValidator-richajaxValidator_example_result.png
===================================================================
(Binary files differ)
Property changes on: root/docs/trunk/Component_Reference/en-US/images/figu-Component_Reference-richajaxValidator-richajaxValidator_example_result.png
___________________________________________________________________
Name: svn:mime-type
+ application/octet-stream
Added: root/docs/trunk/Component_Reference/en-US/images/figu-Component_Reference-richbeanValidator-richbeanValidator_example_result.png
===================================================================
(Binary files differ)
Property changes on: root/docs/trunk/Component_Reference/en-US/images/figu-Component_Reference-richbeanValidator-richbeanValidator_example_result.png
___________________________________________________________________
Name: svn:mime-type
+ application/octet-stream
Added: root/docs/trunk/Component_Reference/en-US/images/figu-Component_Reference-richgraphValidator-Result_from_using_the_value_attribute.png
===================================================================
(Binary files differ)
Property changes on: root/docs/trunk/Component_Reference/en-US/images/figu-Component_Reference-richgraphValidator-Result_from_using_the_value_attribute.png
___________________________________________________________________
Name: svn:mime-type
+ application/octet-stream
Added: root/docs/trunk/Component_Reference/en-US/images/figu-Component_Reference-richgraphValidator-richgraphValidator_example_result.png
===================================================================
(Binary files differ)
Property changes on: root/docs/trunk/Component_Reference/en-US/images/figu-Component_Reference-richgraphValidator-richgraphValidator_example_result.png
___________________________________________________________________
Name: svn:mime-type
+ application/octet-stream
14 years, 3 months
JBoss Rich Faces SVN: r16269 - in branches/community/3.3.X/cdk/maven-archetype-theme/src/main/resources: archetype-resources and 1 other directory.
by richfaces-svn-commits@lists.jboss.org
Author: Alex.Kolonitsky
Date: 2010-01-12 13:11:20 -0500 (Tue, 12 Jan 2010)
New Revision: 16269
Removed:
branches/community/3.3.X/cdk/maven-archetype-theme/src/main/resources/META-INF/maven/archetype-metadata.xml
Modified:
branches/community/3.3.X/cdk/maven-archetype-theme/src/main/resources/archetype-resources/pom.xml
Log:
https://jira.jboss.org/jira/browse/RFPL-285
Update existing CDK archetypes
Deleted: branches/community/3.3.X/cdk/maven-archetype-theme/src/main/resources/META-INF/maven/archetype-metadata.xml
===================================================================
--- branches/community/3.3.X/cdk/maven-archetype-theme/src/main/resources/META-INF/maven/archetype-metadata.xml 2010-01-12 18:05:41 UTC (rev 16268)
+++ branches/community/3.3.X/cdk/maven-archetype-theme/src/main/resources/META-INF/maven/archetype-metadata.xml 2010-01-12 18:11:20 UTC (rev 16269)
@@ -1 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?><archetype-descriptor name="maven-archetype-theme" />
\ No newline at end of file
Modified: branches/community/3.3.X/cdk/maven-archetype-theme/src/main/resources/archetype-resources/pom.xml
===================================================================
--- branches/community/3.3.X/cdk/maven-archetype-theme/src/main/resources/archetype-resources/pom.xml 2010-01-12 18:05:41 UTC (rev 16268)
+++ branches/community/3.3.X/cdk/maven-archetype-theme/src/main/resources/archetype-resources/pom.xml 2010-01-12 18:11:20 UTC (rev 16269)
@@ -57,12 +57,34 @@
<version>1.0</version>
<scope>provided</scope>
</dependency>
-
- <dependency>
- <groupId>javax.faces</groupId>
- <artifactId>jsf-api</artifactId>
- <version>1.2_12</version>
- <scope>provided</scope>
- </dependency>
</dependencies>
+
+ <profiles>
+ <profile>
+ <id>jsf1_2</id>
+ <activation>
+ <activeByDefault>true</activeByDefault>
+ </activation>
+ <dependencies>
+ <dependency>
+ <groupId>javax.faces</groupId>
+ <artifactId>jsf-api</artifactId>
+ <version>1.2_12</version>
+ <scope>provided</scope>
+ </dependency>
+ </dependencies>
+ </profile>
+
+ <profile>
+ <id>jsf2_0</id>
+ <dependencies>
+ <dependency>
+ <groupId>com.sun.faces</groupId>
+ <artifactId>jsf-api</artifactId>
+ <version>2.0.1</version>
+ <scope>provided</scope>
+ </dependency>
+ </dependencies>
+ </profile>
+ </profiles>
</project>
14 years, 3 months
JBoss Rich Faces SVN: r16268 - branches/enterprise/3.3.X/ui/menu-components/src/main/templates/org/richfaces.
by richfaces-svn-commits@lists.jboss.org
Author: konstantin.mishin
Date: 2010-01-12 13:05:41 -0500 (Tue, 12 Jan 2010)
New Revision: 16268
Modified:
branches/enterprise/3.3.X/ui/menu-components/src/main/templates/org/richfaces/htmlMenuItem.jspx
Log:
RFPL-239
porting RF-7540 to enterprise branch
Modified: branches/enterprise/3.3.X/ui/menu-components/src/main/templates/org/richfaces/htmlMenuItem.jspx
===================================================================
--- branches/enterprise/3.3.X/ui/menu-components/src/main/templates/org/richfaces/htmlMenuItem.jspx 2010-01-12 18:03:56 UTC (rev 16267)
+++ branches/enterprise/3.3.X/ui/menu-components/src/main/templates/org/richfaces/htmlMenuItem.jspx 2010-01-12 18:05:41 UTC (rev 16268)
@@ -62,13 +62,11 @@
onmouseout="RichFaces.Menu.itemMouseOut(event, this, '#{menuItemCustomClass}', '#{onmouseoutInlineStyles}', '#{component.attributes['iconClass']}');"
onmouseover="RichFaces.Menu.itemMouseOver(event, this, '#{menuItemHoverClass}', '#{onmouseoverInlineStyles}', '#{component.attributes['iconClass']}');"
- onmouseup="Event.stop(event); #{component.attributes['onmouseup']}"
- onmousedown="Event.stop(event); #{component.attributes['onmousedown']}"
onclick="#{onclick}"
style="#{menuItemStyle}">
<f:call name="utils.encodeAttributes">
- <f:parameter value="onmousemove" />
+ <f:parameter value="onmousemove, onmouseup, onmousedown" />
</f:call>
<jsp:scriptlet><![CDATA[
14 years, 3 months
JBoss Rich Faces SVN: r16267 - branches/enterprise/3.3.X/ui/tree/src/main/java/org/richfaces/component/state.
by richfaces-svn-commits@lists.jboss.org
Author: konstantin.mishin
Date: 2010-01-12 13:03:56 -0500 (Tue, 12 Jan 2010)
New Revision: 16267
Modified:
branches/enterprise/3.3.X/ui/tree/src/main/java/org/richfaces/component/state/TreeState.java
Log:
RFPL-234
porting RF-7273 to enterprise branch
Modified: branches/enterprise/3.3.X/ui/tree/src/main/java/org/richfaces/component/state/TreeState.java
===================================================================
--- branches/enterprise/3.3.X/ui/tree/src/main/java/org/richfaces/component/state/TreeState.java 2010-01-12 18:02:21 UTC (rev 16266)
+++ branches/enterprise/3.3.X/ui/tree/src/main/java/org/richfaces/component/state/TreeState.java 2010-01-12 18:03:56 UTC (rev 16267)
@@ -97,9 +97,9 @@
if (rowKey == null) {
return true;
}
-
- return expandedNodes.contains(rowKey) ||
- NodeState.EXPANDED.equals(queuedNodeStates.get(rowKey));
+ NodeState queuedNodeState = queuedNodeStates.get(rowKey);
+ return expandedNodes.contains(rowKey) && !NodeState.COLLAPSED.equals(queuedNodeState) ||
+ NodeState.EXPANDED.equals(queuedNodeState);
}
public boolean isSelected(TreeRowKey rowKey) {
14 years, 3 months
JBoss Rich Faces SVN: r16266 - branches/enterprise/3.3.X/ui/scrollableDataTable/src/main/javascript/ClientUI/controls/grid.
by richfaces-svn-commits@lists.jboss.org
Author: konstantin.mishin
Date: 2010-01-12 13:02:21 -0500 (Tue, 12 Jan 2010)
New Revision: 16266
Modified:
branches/enterprise/3.3.X/ui/scrollableDataTable/src/main/javascript/ClientUI/controls/grid/GridHeader.js
Log:
RFPL-231
porting RF-6919 to enterprise branch
Modified: branches/enterprise/3.3.X/ui/scrollableDataTable/src/main/javascript/ClientUI/controls/grid/GridHeader.js
===================================================================
--- branches/enterprise/3.3.X/ui/scrollableDataTable/src/main/javascript/ClientUI/controls/grid/GridHeader.js 2010-01-12 15:59:06 UTC (rev 16265)
+++ branches/enterprise/3.3.X/ui/scrollableDataTable/src/main/javascript/ClientUI/controls/grid/GridHeader.js 2010-01-12 18:02:21 UTC (rev 16266)
@@ -357,7 +357,7 @@
}
}
*/
- var rows = this.grid.getBody().templFrozen.getElement().rows;
+ var rows = this.grid.getBody().templNormal.getElement().rows;
var startRow = rows && rows.length>0 ? this.grid.getBody()._getRowIndex(rows[0].id) : 0;
this.grid.element.fire("grid:onsort",{ column: sortColumnId,
startRow: startRow,
14 years, 3 months
JBoss Rich Faces SVN: r16265 - branches/enterprise/3.3.X/ui/contextMenu/src/main/resources/org/richfaces/renderkit/html/scripts.
by richfaces-svn-commits@lists.jboss.org
Author: konstantin.mishin
Date: 2010-01-12 10:59:06 -0500 (Tue, 12 Jan 2010)
New Revision: 16265
Modified:
branches/enterprise/3.3.X/ui/contextMenu/src/main/resources/org/richfaces/renderkit/html/scripts/context-menu.js
Log:
RFPL-232 should not be ported. Reverting changes.
Modified: branches/enterprise/3.3.X/ui/contextMenu/src/main/resources/org/richfaces/renderkit/html/scripts/context-menu.js
===================================================================
--- branches/enterprise/3.3.X/ui/contextMenu/src/main/resources/org/richfaces/renderkit/html/scripts/context-menu.js 2010-01-12 15:52:20 UTC (rev 16264)
+++ branches/enterprise/3.3.X/ui/contextMenu/src/main/resources/org/richfaces/renderkit/html/scripts/context-menu.js 2010-01-12 15:59:06 UTC (rev 16265)
@@ -109,21 +109,11 @@
this.element.appendChild(div);
var html = this.evaluator.invoke('getContent', context||{}).join('');
- html = this.interpolate(html, context);
new Insertion.Top(div, html);
this.menuContent = div;
},
- interpolate: function (placeholders, context) {
- for(var k in context) {
- var v = context[k];
- var regexp = new RegExp("\\{" + k + "\\}", "g");
- placeholders = placeholders.replace(regexp, v);
- }
- return placeholders;
- },
-
destroyMenu: function() {
if (this.menuContent) {
window.RichFaces.Memory.clean(this.menuContent);
14 years, 3 months
JBoss Rich Faces SVN: r16264 - branches/enterprise/3.3.X/ui/contextMenu/src/main/resources/org/richfaces/renderkit/html/scripts.
by richfaces-svn-commits@lists.jboss.org
Author: konstantin.mishin
Date: 2010-01-12 10:52:20 -0500 (Tue, 12 Jan 2010)
New Revision: 16264
Modified:
branches/enterprise/3.3.X/ui/contextMenu/src/main/resources/org/richfaces/renderkit/html/scripts/context-menu.js
Log:
RFPL-232
porting RF-7172 to enterprise branch
Modified: branches/enterprise/3.3.X/ui/contextMenu/src/main/resources/org/richfaces/renderkit/html/scripts/context-menu.js
===================================================================
--- branches/enterprise/3.3.X/ui/contextMenu/src/main/resources/org/richfaces/renderkit/html/scripts/context-menu.js 2010-01-12 15:50:39 UTC (rev 16263)
+++ branches/enterprise/3.3.X/ui/contextMenu/src/main/resources/org/richfaces/renderkit/html/scripts/context-menu.js 2010-01-12 15:52:20 UTC (rev 16264)
@@ -109,11 +109,21 @@
this.element.appendChild(div);
var html = this.evaluator.invoke('getContent', context||{}).join('');
+ html = this.interpolate(html, context);
new Insertion.Top(div, html);
this.menuContent = div;
},
+ interpolate: function (placeholders, context) {
+ for(var k in context) {
+ var v = context[k];
+ var regexp = new RegExp("\\{" + k + "\\}", "g");
+ placeholders = placeholders.replace(regexp, v);
+ }
+ return placeholders;
+ },
+
destroyMenu: function() {
if (this.menuContent) {
window.RichFaces.Memory.clean(this.menuContent);
14 years, 3 months