Author: ppitonak(a)redhat.com
Date: 2011-05-06 14:27:42 -0400 (Fri, 06 May 2011)
New Revision: 22479
Modified:
modules/tests/metamer/trunk/application/src/main/java/org/richfaces/tests/metamer/bean/rich/RichMessageBean.java
modules/tests/metamer/trunk/application/src/main/java/org/richfaces/tests/metamer/bean/rich/RichMessagesBean.java
modules/tests/metamer/trunk/application/src/main/webapp/components/richMessage/csv.xhtml
modules/tests/metamer/trunk/application/src/main/webapp/components/richMessage/jsfValidator.xhtml
modules/tests/metamer/trunk/application/src/main/webapp/components/richMessage/jsr303.xhtml
modules/tests/metamer/trunk/application/src/main/webapp/components/richMessage/list.xhtml
modules/tests/metamer/trunk/application/src/main/webapp/components/richMessages/csv.xhtml
modules/tests/metamer/trunk/application/src/main/webapp/components/richMessages/jsfValidator.xhtml
modules/tests/metamer/trunk/application/src/main/webapp/components/richMessages/jsr303.xhtml
modules/tests/metamer/trunk/application/src/main/webapp/components/richMessages/list.xhtml
modules/tests/metamer/trunk/ftest-source/src/main/java/org/richfaces/tests/metamer/ftest/richMessage/AbstractRichMessageTest.java
modules/tests/metamer/trunk/ftest-source/src/main/java/org/richfaces/tests/metamer/ftest/richMessage/RichMessageAttributes.java
modules/tests/metamer/trunk/ftest-source/src/main/java/org/richfaces/tests/metamer/ftest/richMessage/RichMessageComponentAttributes.java
modules/tests/metamer/trunk/ftest-source/src/main/java/org/richfaces/tests/metamer/ftest/richMessage/RichMessageTest.java
modules/tests/metamer/trunk/ftest-source/src/main/java/org/richfaces/tests/metamer/ftest/richMessage/TestRichMessageCSV.java
modules/tests/metamer/trunk/ftest-source/src/main/java/org/richfaces/tests/metamer/ftest/richMessage/TestRichMessageJSFValidator.java
modules/tests/metamer/trunk/ftest-source/src/main/java/org/richfaces/tests/metamer/ftest/richMessage/TestRichMessageJSR303.java
modules/tests/metamer/trunk/ftest-source/src/main/java/org/richfaces/tests/metamer/ftest/richMessages/RichMessagesTest.java
modules/tests/metamer/trunk/ftest-source/src/main/java/org/richfaces/tests/metamer/ftest/richMessages/TestRichMessagesCSV.java
modules/tests/metamer/trunk/ftest-source/src/main/java/org/richfaces/tests/metamer/ftest/richMessages/TestRichMessagesJSFValidator.java
modules/tests/metamer/trunk/ftest-source/src/main/java/org/richfaces/tests/metamer/ftest/richMessages/TestRichMessagesJSR303.java
Log:
samples and tests for rich:message and rich:messages cleaned, code formatted
Modified:
modules/tests/metamer/trunk/application/src/main/java/org/richfaces/tests/metamer/bean/rich/RichMessageBean.java
===================================================================
---
modules/tests/metamer/trunk/application/src/main/java/org/richfaces/tests/metamer/bean/rich/RichMessageBean.java 2011-05-06
18:23:48 UTC (rev 22478)
+++
modules/tests/metamer/trunk/application/src/main/java/org/richfaces/tests/metamer/bean/rich/RichMessageBean.java 2011-05-06
18:27:42 UTC (rev 22479)
@@ -54,11 +54,11 @@
logger = LoggerFactory.getLogger(getClass());
logger.info("initializing bean " + getClass().getName());
attributes =
Attributes.getComponentAttributesFromFacesConfig(UIRichMessage.class, getClass());
-
+
// setting up incorrect values to fire-up validator
simpleInput1 = "-5";
simpleInput2 = "-5";
-
+
// to get working this component example correctly is required that for
// property has been initialized
attributes.setAttribute("for", "simpleInput1");
Modified:
modules/tests/metamer/trunk/application/src/main/java/org/richfaces/tests/metamer/bean/rich/RichMessagesBean.java
===================================================================
---
modules/tests/metamer/trunk/application/src/main/java/org/richfaces/tests/metamer/bean/rich/RichMessagesBean.java 2011-05-06
18:23:48 UTC (rev 22478)
+++
modules/tests/metamer/trunk/application/src/main/java/org/richfaces/tests/metamer/bean/rich/RichMessagesBean.java 2011-05-06
18:27:42 UTC (rev 22479)
@@ -44,82 +44,80 @@
@ManagedBean(name = "richMessagesBean")
@ViewScoped
public class RichMessagesBean implements Serializable {
-
+
/** Generated UID */
private static final long serialVersionUID = 4893769498631480379L;
// id for input element to bound some FacesMessage to it
private static final String INPUT1_ID = "form:simpleInput1";
private static final String INPUT2_ID = "form:simpleInput2";
-
private static Logger logger;
private Attributes attributes;
-
private String simpleInput1;
private String simpleInput2;
-
+
@PostConstruct
public void init() {
logger = LoggerFactory.getLogger(getClass());
logger.info("initializing bean " + getClass().getName());
attributes =
Attributes.getComponentAttributesFromFacesConfig(UIRichMessages.class, getClass());
-
+
simpleInput1 = "10";
simpleInput2 = "10";
-
+
attributes.setAttribute("ajaxRendered", true);
attributes.setAttribute("rendered", true);
attributes.setAttribute("for", "simpleInput1");
attributes.setAttribute("showSummary", true);
-
+
// add attributes with missing appropriate annotation
attributes.setAttribute("lang", null);
attributes.setAttribute("dir", null);
attributes.setAttribute("style", null);
attributes.setAttribute("styleClass", null);
attributes.setAttribute("title", null);
-
+
attributes.setAttribute("onclick", null);
attributes.setAttribute("ondblclick", null);
attributes.setAttribute("onkeydown", null);
attributes.setAttribute("onkeypress", null);
- attributes.setAttribute("onkeyup", null);
+ attributes.setAttribute("onkeyup", null);
attributes.setAttribute("onmousedown", null);
- attributes.setAttribute("onmousemove", null);
+ attributes.setAttribute("onmousemove", null);
attributes.setAttribute("onmouseup", null);
attributes.setAttribute("onmouseout", null);
attributes.setAttribute("onmouseover", null);
-
+
}
-
+
public void generateFacesError(ActionEvent event) {
-
+
logger.info(" ### Just called generateFacesError()");
- FacesContext.getCurrentInstance().addMessage(null,
- new FacesMessage(FacesMessage.SEVERITY_ERROR,
- "Generated error message without binding to any component
(global)",
+ FacesContext.getCurrentInstance().addMessage(null,
+ new FacesMessage(FacesMessage.SEVERITY_ERROR,
+ "Generated error message without binding to any component
(global)",
"Generated error message without binding to any component
(global)"));
-
- FacesContext.getCurrentInstance().addMessage(null,
- new FacesMessage(FacesMessage.SEVERITY_WARN,
- "Generated warning message without binding to any component
(global)",
+
+ FacesContext.getCurrentInstance().addMessage(null,
+ new FacesMessage(FacesMessage.SEVERITY_WARN,
+ "Generated warning message without binding to any component
(global)",
"Generated warning message without binding to any component
(global)"));
-
+
// Message bound to component on page
- FacesContext.getCurrentInstance().addMessage(INPUT1_ID,
- new FacesMessage(FacesMessage.SEVERITY_ERROR, "Generated error message
for Input 1",
+ FacesContext.getCurrentInstance().addMessage(INPUT1_ID,
+ new FacesMessage(FacesMessage.SEVERITY_ERROR, "Generated error
message for Input 1",
"Generated error message for Input 1"));
-
- FacesContext.getCurrentInstance().addMessage(INPUT1_ID,
- new FacesMessage(FacesMessage.SEVERITY_WARN, "Generated warning message
for Input 1",
+
+ FacesContext.getCurrentInstance().addMessage(INPUT1_ID,
+ new FacesMessage(FacesMessage.SEVERITY_WARN, "Generated warning
message for Input 1",
"Generated warning message for Input 1"));
-
- FacesContext.getCurrentInstance().addMessage(INPUT2_ID,
- new FacesMessage(FacesMessage.SEVERITY_ERROR, "Generated error message
for Input 2",
+
+ FacesContext.getCurrentInstance().addMessage(INPUT2_ID,
+ new FacesMessage(FacesMessage.SEVERITY_ERROR, "Generated error
message for Input 2",
"Generated error message for Input 2"));
-
- FacesContext.getCurrentInstance().addMessage(INPUT2_ID,
- new FacesMessage(FacesMessage.SEVERITY_WARN, "Generated warning message
for Input 2",
+
+ FacesContext.getCurrentInstance().addMessage(INPUT2_ID,
+ new FacesMessage(FacesMessage.SEVERITY_WARN, "Generated warning
message for Input 2",
"Generated warning message for Input 2"));
}
@@ -146,5 +144,4 @@
public void setSimpleInput2(String simpleInput2) {
this.simpleInput2 = simpleInput2;
}
-
}
Modified:
modules/tests/metamer/trunk/application/src/main/webapp/components/richMessage/csv.xhtml
===================================================================
---
modules/tests/metamer/trunk/application/src/main/webapp/components/richMessage/csv.xhtml 2011-05-06
18:23:48 UTC (rev 22478)
+++
modules/tests/metamer/trunk/application/src/main/webapp/components/richMessage/csv.xhtml 2011-05-06
18:27:42 UTC (rev 22479)
@@ -48,99 +48,99 @@
<ui:define name="component">
<script type="text/javascript">
function setCorrectValues() {
- $('input[id$=simpleInput1]').val('4');
- $('input[id$=simpleInput2]').val('4');
+ $('input[id$=simpleInput1]').val('4');
+ $('input[id$=simpleInput2]').val('4');
}
function setWrongValues() {
- $('input[id$=simpleInput1]').val('-5');
- $('input[id$=simpleInput2]').val('-5');
+ $('input[id$=simpleInput1]').val('-5');
+ $('input[id$=simpleInput2]').val('-5');
}
</script>
<input id="setCorrectValuesButton" type="button"
value="set correct values" onclick="setCorrectValues()"/>
<input id="setWrongValuesButton" type="button"
value="set wrong values" onclick="setWrongValues()"/>
-
+
<rich:message id="simpleInputMsg"
-
ajaxRendered="#{richMessageBean.attributes['ajaxRendered'].value}"
- for="#{richMessageBean.attributes['for'].value}"
-
keepTransient="#{richMessageBean.attributes['keepTransient'].value}"
-
rendered="#{richMessageBean.attributes['rendered'].value}"
-
showDetail="#{richMessageBean.attributes['showDetail'].value}"
-
showSummary="#{richMessageBean.attributes['showSummary'].value}"
- dir="#{richMessageBean.attributes['dir'].value}"
- lang="#{richMessageBean.attributes['lang'].value}"
-
onclick="#{richMessageBean.attributes['onclick'].value}"
-
ondblclick="#{richMessageBean.attributes['ondblclick'].value}"
-
onkeyup="#{richMessageBean.attributes['onkeyup'].value}"
-
onkeydown="#{richMessageBean.attributes['onkeydown'].value}"
-
onkeypress="#{richMessageBean.attributes['onkeypress'].value}"
-
onmousedown="#{richMessageBean.attributes['onmousedown'].value}"
-
onmousemove="#{richMessageBean.attributes['onmousemove'].value}"
-
onmouseout="#{richMessageBean.attributes['onmouseout'].value}"
-
onmouseover="#{richMessageBean.attributes['onmouseover'].value}"
-
onmouseup="#{richMessageBean.attributes['onmouseup'].value}"
- style="#{richMessageBean.attributes['style'].value}"
-
styleClass="#{richMessageBean.attributes['styleClass'].value}"
-
title="#{richMessageBean.attributes['title'].value}"
- />
+
ajaxRendered="#{richMessageBean.attributes['ajaxRendered'].value}"
+
for="#{richMessageBean.attributes['for'].value}"
+
keepTransient="#{richMessageBean.attributes['keepTransient'].value}"
+
rendered="#{richMessageBean.attributes['rendered'].value}"
+
showDetail="#{richMessageBean.attributes['showDetail'].value}"
+
showSummary="#{richMessageBean.attributes['showSummary'].value}"
+
dir="#{richMessageBean.attributes['dir'].value}"
+
lang="#{richMessageBean.attributes['lang'].value}"
+
onclick="#{richMessageBean.attributes['onclick'].value}"
+
ondblclick="#{richMessageBean.attributes['ondblclick'].value}"
+
onkeyup="#{richMessageBean.attributes['onkeyup'].value}"
+
onkeydown="#{richMessageBean.attributes['onkeydown'].value}"
+
onkeypress="#{richMessageBean.attributes['onkeypress'].value}"
+
onmousedown="#{richMessageBean.attributes['onmousedown'].value}"
+
onmousemove="#{richMessageBean.attributes['onmousemove'].value}"
+
onmouseout="#{richMessageBean.attributes['onmouseout'].value}"
+
onmouseover="#{richMessageBean.attributes['onmouseover'].value}"
+
onmouseup="#{richMessageBean.attributes['onmouseup'].value}"
+
style="#{richMessageBean.attributes['style'].value}"
+
styleClass="#{richMessageBean.attributes['styleClass'].value}"
+
title="#{richMessageBean.attributes['title'].value}"
+ />
<h:panelGrid columns="3">
- <h:outputLabel for="simpleInput1"
value="#{minMaxBean.description}" />
+ <h:outputLabel for="simpleInput1"
value="#{minMaxBean.description}" />
<h:inputText id="simpleInput1"
value="#{minMaxBean.value}" label="Input 1"
converter="#{minMaxBean.converter}">
- <rich:validator />
- </h:inputText>
+ <rich:validator />
+ </h:inputText>
<rich:message id="simpleInputMsg1"
-
ajaxRendered="#{richMessageBean.attributes['ajaxRendered'].value}"
- for="simpleInput1"
-
keepTransient="#{richMessageBean.attributes['keepTransient'].value}"
-
rendered="#{richMessageBean.attributes['rendered'].value}"
-
showDetail="#{richMessageBean.attributes['showDetail'].value}"
-
showSummary="#{richMessageBean.attributes['showSummary'].value}"
- dir="#{richMessageBean.attributes['dir'].value}"
-
lang="#{richMessageBean.attributes['lang'].value}"
-
onclick="#{richMessageBean.attributes['onclick'].value}"
-
ondblclick="#{richMessageBean.attributes['ondblclick'].value}"
- onkeyup="#{richMessageBean.attributes['onkeyup'].value}"
-
onkeydown="#{richMessageBean.attributes['onkeydown'].value}"
-
onkeypress="#{richMessageBean.attributes['onkeypress'].value}"
-
onmousedown="#{richMessageBean.attributes['onmousedown'].value}"
-
onmousemove="#{richMessageBean.attributes['onmousemove'].value}"
-
onmouseout="#{richMessageBean.attributes['onmouseout'].value}"
-
onmouseover="#{richMessageBean.attributes['onmouseover'].value}"
-
onmouseup="#{richMessageBean.attributes['onmouseup'].value}"
-
style="#{richMessageBean.attributes['style'].value}"
-
styleClass="#{richMessageBean.attributes['styleClass'].value}"
-
title="#{richMessageBean.attributes['title'].value}"
- />
-
+
ajaxRendered="#{richMessageBean.attributes['ajaxRendered'].value}"
+ for="simpleInput1"
+
keepTransient="#{richMessageBean.attributes['keepTransient'].value}"
+
rendered="#{richMessageBean.attributes['rendered'].value}"
+
showDetail="#{richMessageBean.attributes['showDetail'].value}"
+
showSummary="#{richMessageBean.attributes['showSummary'].value}"
+
dir="#{richMessageBean.attributes['dir'].value}"
+
lang="#{richMessageBean.attributes['lang'].value}"
+
onclick="#{richMessageBean.attributes['onclick'].value}"
+
ondblclick="#{richMessageBean.attributes['ondblclick'].value}"
+
onkeyup="#{richMessageBean.attributes['onkeyup'].value}"
+
onkeydown="#{richMessageBean.attributes['onkeydown'].value}"
+
onkeypress="#{richMessageBean.attributes['onkeypress'].value}"
+
onmousedown="#{richMessageBean.attributes['onmousedown'].value}"
+
onmousemove="#{richMessageBean.attributes['onmousemove'].value}"
+
onmouseout="#{richMessageBean.attributes['onmouseout'].value}"
+
onmouseover="#{richMessageBean.attributes['onmouseover'].value}"
+
onmouseup="#{richMessageBean.attributes['onmouseup'].value}"
+
style="#{richMessageBean.attributes['style'].value}"
+
styleClass="#{richMessageBean.attributes['styleClass'].value}"
+
title="#{richMessageBean.attributes['title'].value}"
+ />
+
<h:outputLabel for="simpleInput2"
value="#{minMaxBean.description}" />
<h:inputText id="simpleInput2"
value="#{minMaxBean.value}" label="Input 2"
converter="#{minMaxBean.converter}">
- <rich:validator />
+ <rich:validator />
</h:inputText>
<rich:message id="simpleInputMsg2"
-
ajaxRendered="#{richMessageBean.attributes['ajaxRendered'].value}"
- for="simpleInput2"
-
keepTransient="#{richMessageBean.attributes['keepTransient'].value}"
-
rendered="#{richMessageBean.attributes['rendered'].value}"
-
showDetail="#{richMessageBean.attributes['showDetail'].value}"
-
showSummary="#{richMessageBean.attributes['showSummary'].value}"
- dir="#{richMessageBean.attributes['dir'].value}"
-
lang="#{richMessageBean.attributes['lang'].value}"
-
onclick="#{richMessageBean.attributes['onclick'].value}"
-
ondblclick="#{richMessageBean.attributes['ondblclick'].value}"
-
onkeyup="#{richMessageBean.attributes['onkeyup'].value}"
-
onkeydown="#{richMessageBean.attributes['onkeydown'].value}"
-
onkeypress="#{richMessageBean.attributes['onkeypress'].value}"
-
onmousedown="#{richMessageBean.attributes['onmousedown'].value}"
-
onmousemove="#{richMessageBean.attributes['onmousemove'].value}"
-
onmouseout="#{richMessageBean.attributes['onmouseout'].value}"
-
onmouseover="#{richMessageBean.attributes['onmouseover'].value}"
-
onmouseup="#{richMessageBean.attributes['onmouseup'].value}"
-
style="#{richMessageBean.attributes['style'].value}"
-
styleClass="#{richMessageBean.attributes['styleClass'].value}"
-
title="#{richMessageBean.attributes['title'].value}"
- />
-
+
ajaxRendered="#{richMessageBean.attributes['ajaxRendered'].value}"
+ for="simpleInput2"
+
keepTransient="#{richMessageBean.attributes['keepTransient'].value}"
+
rendered="#{richMessageBean.attributes['rendered'].value}"
+
showDetail="#{richMessageBean.attributes['showDetail'].value}"
+
showSummary="#{richMessageBean.attributes['showSummary'].value}"
+
dir="#{richMessageBean.attributes['dir'].value}"
+
lang="#{richMessageBean.attributes['lang'].value}"
+
onclick="#{richMessageBean.attributes['onclick'].value}"
+
ondblclick="#{richMessageBean.attributes['ondblclick'].value}"
+
onkeyup="#{richMessageBean.attributes['onkeyup'].value}"
+
onkeydown="#{richMessageBean.attributes['onkeydown'].value}"
+
onkeypress="#{richMessageBean.attributes['onkeypress'].value}"
+
onmousedown="#{richMessageBean.attributes['onmousedown'].value}"
+
onmousemove="#{richMessageBean.attributes['onmousemove'].value}"
+
onmouseout="#{richMessageBean.attributes['onmouseout'].value}"
+
onmouseover="#{richMessageBean.attributes['onmouseover'].value}"
+
onmouseup="#{richMessageBean.attributes['onmouseup'].value}"
+
style="#{richMessageBean.attributes['style'].value}"
+
styleClass="#{richMessageBean.attributes['styleClass'].value}"
+
title="#{richMessageBean.attributes['title'].value}"
+ />
+
</h:panelGrid>
<br/>
Modified:
modules/tests/metamer/trunk/application/src/main/webapp/components/richMessage/jsfValidator.xhtml
===================================================================
---
modules/tests/metamer/trunk/application/src/main/webapp/components/richMessage/jsfValidator.xhtml 2011-05-06
18:23:48 UTC (rev 22478)
+++
modules/tests/metamer/trunk/application/src/main/webapp/components/richMessage/jsfValidator.xhtml 2011-05-06
18:27:42 UTC (rev 22479)
@@ -39,112 +39,112 @@
</f:viewParam>
</f:metadata>
</ui:define>
-
+
<ui:define name="component">
- <script type="text/javascript">
- function setCorrectValues() {
- $('input[id$=simpleInput1]').val('4');
- $('input[id$=simpleInput2]').val('4');
- }
+ <script type="text/javascript">
+ function setCorrectValues() {
+ $('input[id$=simpleInput1]').val('4');
+ $('input[id$=simpleInput2]').val('4');
+ }
- function setWrongValues() {
- $('input[id$=simpleInput1]').val('-5');
- $('input[id$=simpleInput2]').val('-5');
- }
+ function setWrongValues() {
+ $('input[id$=simpleInput1]').val('-5');
+ $('input[id$=simpleInput2]').val('-5');
+ }
</script>
<input id="setCorrectValuesButton" type="button"
value="set correct values" onclick="setCorrectValues()"/>
<input id="setWrongValuesButton" type="button"
value="set wrong values" onclick="setWrongValues()"/>
-
+
<rich:message id="simpleInputMsg"
-
ajaxRendered="#{richMessageBean.attributes['ajaxRendered'].value}"
- for="#{richMessageBean.attributes['for'].value}"
-
keepTransient="#{richMessageBean.attributes['keepTransient'].value}"
-
rendered="#{richMessageBean.attributes['rendered'].value}"
-
showDetail="#{richMessageBean.attributes['showDetail'].value}"
-
showSummary="#{richMessageBean.attributes['showSummary'].value}"
- dir="#{richMessageBean.attributes['dir'].value}"
- lang="#{richMessageBean.attributes['lang'].value}"
-
onclick="#{richMessageBean.attributes['onclick'].value}"
-
ondblclick="#{richMessageBean.attributes['ondblclick'].value}"
-
onkeyup="#{richMessageBean.attributes['onkeyup'].value}"
-
onkeydown="#{richMessageBean.attributes['onkeydown'].value}"
-
onkeypress="#{richMessageBean.attributes['onkeypress'].value}"
-
onmousedown="#{richMessageBean.attributes['onmousedown'].value}"
-
onmousemove="#{richMessageBean.attributes['onmousemove'].value}"
-
onmouseout="#{richMessageBean.attributes['onmouseout'].value}"
-
onmouseover="#{richMessageBean.attributes['onmouseover'].value}"
-
onmouseup="#{richMessageBean.attributes['onmouseup'].value}"
- style="#{richMessageBean.attributes['style'].value}"
-
styleClass="#{richMessageBean.attributes['styleClass'].value}"
-
title="#{richMessageBean.attributes['title'].value}"
- />
-
+
ajaxRendered="#{richMessageBean.attributes['ajaxRendered'].value}"
+
for="#{richMessageBean.attributes['for'].value}"
+
keepTransient="#{richMessageBean.attributes['keepTransient'].value}"
+
rendered="#{richMessageBean.attributes['rendered'].value}"
+
showDetail="#{richMessageBean.attributes['showDetail'].value}"
+
showSummary="#{richMessageBean.attributes['showSummary'].value}"
+
dir="#{richMessageBean.attributes['dir'].value}"
+
lang="#{richMessageBean.attributes['lang'].value}"
+
onclick="#{richMessageBean.attributes['onclick'].value}"
+
ondblclick="#{richMessageBean.attributes['ondblclick'].value}"
+
onkeyup="#{richMessageBean.attributes['onkeyup'].value}"
+
onkeydown="#{richMessageBean.attributes['onkeydown'].value}"
+
onkeypress="#{richMessageBean.attributes['onkeypress'].value}"
+
onmousedown="#{richMessageBean.attributes['onmousedown'].value}"
+
onmousemove="#{richMessageBean.attributes['onmousemove'].value}"
+
onmouseout="#{richMessageBean.attributes['onmouseout'].value}"
+
onmouseover="#{richMessageBean.attributes['onmouseover'].value}"
+
onmouseup="#{richMessageBean.attributes['onmouseup'].value}"
+
style="#{richMessageBean.attributes['style'].value}"
+
styleClass="#{richMessageBean.attributes['styleClass'].value}"
+
title="#{richMessageBean.attributes['title'].value}"
+ />
+
<h:panelGrid columns="3">
- <h:outputLabel for="simpleInput1"
value="#{minMaxBean.description}" />
+ <h:outputLabel for="simpleInput1"
value="#{minMaxBean.description}" />
<h:inputText id="simpleInput1"
value="#{richMessageBean.simpleInput1}" label="Input 1" >
- <f:validateLongRange minimum="2" maximum="10"
/>
+ <f:validateLongRange minimum="2" maximum="10"
/>
</h:inputText>
<rich:message id="simpleInputMsg1"
-
ajaxRendered="#{richMessageBean.attributes['ajaxRendered'].value}"
- for="simpleInput1"
-
keepTransient="#{richMessageBean.attributes['keepTransient'].value}"
-
rendered="#{richMessageBean.attributes['rendered'].value}"
-
showDetail="#{richMessageBean.attributes['showDetail'].value}"
-
showSummary="#{richMessageBean.attributes['showSummary'].value}"
- dir="#{richMessageBean.attributes['dir'].value}"
-
lang="#{richMessageBean.attributes['lang'].value}"
-
onclick="#{richMessageBean.attributes['onclick'].value}"
-
ondblclick="#{richMessageBean.attributes['ondblclick'].value}"
-
onkeyup="#{richMessageBean.attributes['onkeyup'].value}"
-
onkeydown="#{richMessageBean.attributes['onkeydown'].value}"
-
onkeypress="#{richMessageBean.attributes['onkeypress'].value}"
-
onmousedown="#{richMessageBean.attributes['onmousedown'].value}"
-
onmousemove="#{richMessageBean.attributes['onmousemove'].value}"
-
onmouseout="#{richMessageBean.attributes['onmouseout'].value}"
-
onmouseover="#{richMessageBean.attributes['onmouseover'].value}"
-
onmouseup="#{richMessageBean.attributes['onmouseup'].value}"
-
style="#{richMessageBean.attributes['style'].value}"
-
styleClass="#{richMessageBean.attributes['styleClass'].value}"
-
title="#{richMessageBean.attributes['title'].value}"
- />
+
ajaxRendered="#{richMessageBean.attributes['ajaxRendered'].value}"
+ for="simpleInput1"
+
keepTransient="#{richMessageBean.attributes['keepTransient'].value}"
+
rendered="#{richMessageBean.attributes['rendered'].value}"
+
showDetail="#{richMessageBean.attributes['showDetail'].value}"
+
showSummary="#{richMessageBean.attributes['showSummary'].value}"
+
dir="#{richMessageBean.attributes['dir'].value}"
+
lang="#{richMessageBean.attributes['lang'].value}"
+
onclick="#{richMessageBean.attributes['onclick'].value}"
+
ondblclick="#{richMessageBean.attributes['ondblclick'].value}"
+
onkeyup="#{richMessageBean.attributes['onkeyup'].value}"
+
onkeydown="#{richMessageBean.attributes['onkeydown'].value}"
+
onkeypress="#{richMessageBean.attributes['onkeypress'].value}"
+
onmousedown="#{richMessageBean.attributes['onmousedown'].value}"
+
onmousemove="#{richMessageBean.attributes['onmousemove'].value}"
+
onmouseout="#{richMessageBean.attributes['onmouseout'].value}"
+
onmouseover="#{richMessageBean.attributes['onmouseover'].value}"
+
onmouseup="#{richMessageBean.attributes['onmouseup'].value}"
+
style="#{richMessageBean.attributes['style'].value}"
+
styleClass="#{richMessageBean.attributes['styleClass'].value}"
+
title="#{richMessageBean.attributes['title'].value}"
+ />
</h:panelGrid>
-
+
<h:panelGrid columns="3">
- <h:outputLabel for="simpleInput2"
value="#{minMaxBean.description}" />
+ <h:outputLabel for="simpleInput2"
value="#{minMaxBean.description}" />
<h:inputText id="simpleInput2"
value="#{richMessageBean.simpleInput2}" label="Input 2" >
- <f:validateLongRange minimum="2" maximum="10"
/>
+ <f:validateLongRange minimum="2" maximum="10"
/>
</h:inputText>
<rich:message id="simpleInputMsg2"
-
ajaxRendered="#{richMessageBean.attributes['ajaxRendered'].value}"
- for="simpleInput2"
-
keepTransient="#{richMessageBean.attributes['keepTransient'].value}"
-
rendered="#{richMessageBean.attributes['rendered'].value}"
-
showDetail="#{richMessageBean.attributes['showDetail'].value}"
-
showSummary="#{richMessageBean.attributes['showSummary'].value}"
- dir="#{richMessageBean.attributes['dir'].value}"
-
lang="#{richMessageBean.attributes['lang'].value}"
-
onclick="#{richMessageBean.attributes['onclick'].value}"
-
ondblclick="#{richMessageBean.attributes['ondblclick'].value}"
-
onkeyup="#{richMessageBean.attributes['onkeyup'].value}"
-
onkeydown="#{richMessageBean.attributes['onkeydown'].value}"
-
onkeypress="#{richMessageBean.attributes['onkeypress'].value}"
-
onmousedown="#{richMessageBean.attributes['onmousedown'].value}"
-
onmousemove="#{richMessageBean.attributes['onmousemove'].value}"
-
onmouseout="#{richMessageBean.attributes['onmouseout'].value}"
-
onmouseover="#{richMessageBean.attributes['onmouseover'].value}"
-
onmouseup="#{richMessageBean.attributes['onmouseup'].value}"
-
style="#{richMessageBean.attributes['style'].value}"
-
styleClass="#{richMessageBean.attributes['styleClass'].value}"
-
title="#{richMessageBean.attributes['title'].value}"
- />
+
ajaxRendered="#{richMessageBean.attributes['ajaxRendered'].value}"
+ for="simpleInput2"
+
keepTransient="#{richMessageBean.attributes['keepTransient'].value}"
+
rendered="#{richMessageBean.attributes['rendered'].value}"
+
showDetail="#{richMessageBean.attributes['showDetail'].value}"
+
showSummary="#{richMessageBean.attributes['showSummary'].value}"
+
dir="#{richMessageBean.attributes['dir'].value}"
+
lang="#{richMessageBean.attributes['lang'].value}"
+
onclick="#{richMessageBean.attributes['onclick'].value}"
+
ondblclick="#{richMessageBean.attributes['ondblclick'].value}"
+
onkeyup="#{richMessageBean.attributes['onkeyup'].value}"
+
onkeydown="#{richMessageBean.attributes['onkeydown'].value}"
+
onkeypress="#{richMessageBean.attributes['onkeypress'].value}"
+
onmousedown="#{richMessageBean.attributes['onmousedown'].value}"
+
onmousemove="#{richMessageBean.attributes['onmousemove'].value}"
+
onmouseout="#{richMessageBean.attributes['onmouseout'].value}"
+
onmouseover="#{richMessageBean.attributes['onmouseover'].value}"
+
onmouseup="#{richMessageBean.attributes['onmouseup'].value}"
+
style="#{richMessageBean.attributes['style'].value}"
+
styleClass="#{richMessageBean.attributes['styleClass'].value}"
+
title="#{richMessageBean.attributes['title'].value}"
+ />
</h:panelGrid>
-
+
<br/>
-
+
<h:commandButton id="hButton" value="h:commandButton"
style="margin-right: 10px;"/>
<a4j:commandButton id="a4jButton"
value="a4j:commandButton"/>
-
+
<br/>
<rich:messages id="msgs"/>
</ui:define>
Modified:
modules/tests/metamer/trunk/application/src/main/webapp/components/richMessage/jsr303.xhtml
===================================================================
---
modules/tests/metamer/trunk/application/src/main/webapp/components/richMessage/jsr303.xhtml 2011-05-06
18:23:48 UTC (rev 22478)
+++
modules/tests/metamer/trunk/application/src/main/webapp/components/richMessage/jsr303.xhtml 2011-05-06
18:27:42 UTC (rev 22479)
@@ -48,94 +48,94 @@
<ui:define name="component">
<script type="text/javascript">
function setCorrectValues() {
- $('input[id$=simpleInput1]').val('4');
- $('input[id$=simpleInput2]').val('4');
+ $('input[id$=simpleInput1]').val('4');
+ $('input[id$=simpleInput2]').val('4');
}
function setWrongValues() {
- $('input[id$=simpleInput1]').val('-5');
- $('input[id$=simpleInput2]').val('-5');
+ $('input[id$=simpleInput1]').val('-5');
+ $('input[id$=simpleInput2]').val('-5');
}
</script>
<input id="setCorrectValuesButton" type="button"
value="set correct values" onclick="setCorrectValues()"/>
<input id="setWrongValuesButton" type="button"
value="set wrong values" onclick="setWrongValues()"/>
- <rich:message id="simpleInputMsg"
-
ajaxRendered="#{richMessageBean.attributes['ajaxRendered'].value}"
- for="#{richMessageBean.attributes['for'].value}"
-
keepTransient="#{richMessageBean.attributes['keepTransient'].value}"
-
rendered="#{richMessageBean.attributes['rendered'].value}"
-
showDetail="#{richMessageBean.attributes['showDetail'].value}"
-
showSummary="#{richMessageBean.attributes['showSummary'].value}"
- dir="#{richMessageBean.attributes['dir'].value}"
- lang="#{richMessageBean.attributes['lang'].value}"
-
onclick="#{richMessageBean.attributes['onclick'].value}"
-
ondblclick="#{richMessageBean.attributes['ondblclick'].value}"
-
onkeyup="#{richMessageBean.attributes['onkeyup'].value}"
-
onkeydown="#{richMessageBean.attributes['onkeydown'].value}"
-
onkeypress="#{richMessageBean.attributes['onkeypress'].value}"
-
onmousedown="#{richMessageBean.attributes['onmousedown'].value}"
-
onmousemove="#{richMessageBean.attributes['onmousemove'].value}"
-
onmouseout="#{richMessageBean.attributes['onmouseout'].value}"
-
onmouseover="#{richMessageBean.attributes['onmouseover'].value}"
-
onmouseup="#{richMessageBean.attributes['onmouseup'].value}"
- style="#{richMessageBean.attributes['style'].value}"
-
styleClass="#{richMessageBean.attributes['styleClass'].value}"
-
title="#{richMessageBean.attributes['title'].value}"
- />
+ <rich:message id="simpleInputMsg"
+
ajaxRendered="#{richMessageBean.attributes['ajaxRendered'].value}"
+
for="#{richMessageBean.attributes['for'].value}"
+
keepTransient="#{richMessageBean.attributes['keepTransient'].value}"
+
rendered="#{richMessageBean.attributes['rendered'].value}"
+
showDetail="#{richMessageBean.attributes['showDetail'].value}"
+
showSummary="#{richMessageBean.attributes['showSummary'].value}"
+
dir="#{richMessageBean.attributes['dir'].value}"
+
lang="#{richMessageBean.attributes['lang'].value}"
+
onclick="#{richMessageBean.attributes['onclick'].value}"
+
ondblclick="#{richMessageBean.attributes['ondblclick'].value}"
+
onkeyup="#{richMessageBean.attributes['onkeyup'].value}"
+
onkeydown="#{richMessageBean.attributes['onkeydown'].value}"
+
onkeypress="#{richMessageBean.attributes['onkeypress'].value}"
+
onmousedown="#{richMessageBean.attributes['onmousedown'].value}"
+
onmousemove="#{richMessageBean.attributes['onmousemove'].value}"
+
onmouseout="#{richMessageBean.attributes['onmouseout'].value}"
+
onmouseover="#{richMessageBean.attributes['onmouseover'].value}"
+
onmouseup="#{richMessageBean.attributes['onmouseup'].value}"
+
style="#{richMessageBean.attributes['style'].value}"
+
styleClass="#{richMessageBean.attributes['styleClass'].value}"
+
title="#{richMessageBean.attributes['title'].value}"
+ />
<h:panelGrid columns="3">
- <h:outputLabel for="simpleInput1"
value="#{minMaxBean.description}" />
- <h:inputText id="simpleInput1" value="#{minMaxBean.value}"
label="Input 1" converter="#{minMaxBean.converter}"/>
- <rich:message id="simpleInputMsg1"
-
ajaxRendered="#{richMessageBean.attributes['ajaxRendered'].value}"
- for="simpleInput1"
-
keepTransient="#{richMessageBean.attributes['keepTransient'].value}"
-
rendered="#{richMessageBean.attributes['rendered'].value}"
-
showDetail="#{richMessageBean.attributes['showDetail'].value}"
-
showSummary="#{richMessageBean.attributes['showSummary'].value}"
- dir="#{richMessageBean.attributes['dir'].value}"
-
lang="#{richMessageBean.attributes['lang'].value}"
-
onclick="#{richMessageBean.attributes['onclick'].value}"
-
ondblclick="#{richMessageBean.attributes['ondblclick'].value}"
-
onkeyup="#{richMessageBean.attributes['onkeyup'].value}"
-
onkeydown="#{richMessageBean.attributes['onkeydown'].value}"
-
onkeypress="#{richMessageBean.attributes['onkeypress'].value}"
-
onmousedown="#{richMessageBean.attributes['onmousedown'].value}"
-
onmousemove="#{richMessageBean.attributes['onmousemove'].value}"
-
onmouseout="#{richMessageBean.attributes['onmouseout'].value}"
-
onmouseover="#{richMessageBean.attributes['onmouseover'].value}"
-
onmouseup="#{richMessageBean.attributes['onmouseup'].value}"
-
style="#{richMessageBean.attributes['style'].value}"
-
styleClass="#{richMessageBean.attributes['styleClass'].value}"
-
title="#{richMessageBean.attributes['title'].value}"
- />
-
- <h:outputLabel for="simpleInput2"
value="#{minMaxBean.description}" />
- <h:inputText id="simpleInput2"
value="#{minMaxBean.value}" label="Input 2"
converter="#{minMaxBean.converter}"/>
- <rich:message id="simpleInputMsg2"
-
ajaxRendered="#{richMessageBean.attributes['ajaxRendered'].value}"
- for="simpleInput2"
-
keepTransient="#{richMessageBean.attributes['keepTransient'].value}"
-
rendered="#{richMessageBean.attributes['rendered'].value}"
-
showDetail="#{richMessageBean.attributes['showDetail'].value}"
-
showSummary="#{richMessageBean.attributes['showSummary'].value}"
- dir="#{richMessageBean.attributes['dir'].value}"
- lang="#{richMessageBean.attributes['lang'].value}"
-
onclick="#{richMessageBean.attributes['onclick'].value}"
-
ondblclick="#{richMessageBean.attributes['ondblclick'].value}"
-
onkeyup="#{richMessageBean.attributes['onkeyup'].value}"
-
onkeydown="#{richMessageBean.attributes['onkeydown'].value}"
-
onkeypress="#{richMessageBean.attributes['onkeypress'].value}"
-
onmousedown="#{richMessageBean.attributes['onmousedown'].value}"
-
onmousemove="#{richMessageBean.attributes['onmousemove'].value}"
-
onmouseout="#{richMessageBean.attributes['onmouseout'].value}"
-
onmouseover="#{richMessageBean.attributes['onmouseover'].value}"
-
onmouseup="#{richMessageBean.attributes['onmouseup'].value}"
- style="#{richMessageBean.attributes['style'].value}"
-
styleClass="#{richMessageBean.attributes['styleClass'].value}"
-
title="#{richMessageBean.attributes['title'].value}"
- />
+ <h:outputLabel for="simpleInput1"
value="#{minMaxBean.description}" />
+ <h:inputText id="simpleInput1"
value="#{minMaxBean.value}" label="Input 1"
converter="#{minMaxBean.converter}"/>
+ <rich:message id="simpleInputMsg1"
+
ajaxRendered="#{richMessageBean.attributes['ajaxRendered'].value}"
+ for="simpleInput1"
+
keepTransient="#{richMessageBean.attributes['keepTransient'].value}"
+
rendered="#{richMessageBean.attributes['rendered'].value}"
+
showDetail="#{richMessageBean.attributes['showDetail'].value}"
+
showSummary="#{richMessageBean.attributes['showSummary'].value}"
+
dir="#{richMessageBean.attributes['dir'].value}"
+
lang="#{richMessageBean.attributes['lang'].value}"
+
onclick="#{richMessageBean.attributes['onclick'].value}"
+
ondblclick="#{richMessageBean.attributes['ondblclick'].value}"
+
onkeyup="#{richMessageBean.attributes['onkeyup'].value}"
+
onkeydown="#{richMessageBean.attributes['onkeydown'].value}"
+
onkeypress="#{richMessageBean.attributes['onkeypress'].value}"
+
onmousedown="#{richMessageBean.attributes['onmousedown'].value}"
+
onmousemove="#{richMessageBean.attributes['onmousemove'].value}"
+
onmouseout="#{richMessageBean.attributes['onmouseout'].value}"
+
onmouseover="#{richMessageBean.attributes['onmouseover'].value}"
+
onmouseup="#{richMessageBean.attributes['onmouseup'].value}"
+
style="#{richMessageBean.attributes['style'].value}"
+
styleClass="#{richMessageBean.attributes['styleClass'].value}"
+
title="#{richMessageBean.attributes['title'].value}"
+ />
+
+ <h:outputLabel for="simpleInput2"
value="#{minMaxBean.description}" />
+ <h:inputText id="simpleInput2"
value="#{minMaxBean.value}" label="Input 2"
converter="#{minMaxBean.converter}"/>
+ <rich:message id="simpleInputMsg2"
+
ajaxRendered="#{richMessageBean.attributes['ajaxRendered'].value}"
+ for="simpleInput2"
+
keepTransient="#{richMessageBean.attributes['keepTransient'].value}"
+
rendered="#{richMessageBean.attributes['rendered'].value}"
+
showDetail="#{richMessageBean.attributes['showDetail'].value}"
+
showSummary="#{richMessageBean.attributes['showSummary'].value}"
+
dir="#{richMessageBean.attributes['dir'].value}"
+
lang="#{richMessageBean.attributes['lang'].value}"
+
onclick="#{richMessageBean.attributes['onclick'].value}"
+
ondblclick="#{richMessageBean.attributes['ondblclick'].value}"
+
onkeyup="#{richMessageBean.attributes['onkeyup'].value}"
+
onkeydown="#{richMessageBean.attributes['onkeydown'].value}"
+
onkeypress="#{richMessageBean.attributes['onkeypress'].value}"
+
onmousedown="#{richMessageBean.attributes['onmousedown'].value}"
+
onmousemove="#{richMessageBean.attributes['onmousemove'].value}"
+
onmouseout="#{richMessageBean.attributes['onmouseout'].value}"
+
onmouseover="#{richMessageBean.attributes['onmouseover'].value}"
+
onmouseup="#{richMessageBean.attributes['onmouseup'].value}"
+
style="#{richMessageBean.attributes['style'].value}"
+
styleClass="#{richMessageBean.attributes['styleClass'].value}"
+
title="#{richMessageBean.attributes['title'].value}"
+ />
</h:panelGrid>
<br/>
@@ -148,7 +148,7 @@
</ui:define>
<ui:define name="outOfTemplateAfter">
- <metamer:attributes value="#{richMessageBean.attributes}"
id="attributes"/>
+ <metamer:attributes value="#{richMessageBean.attributes}"
id="attributes"/>
</ui:define>
</ui:composition>
Modified:
modules/tests/metamer/trunk/application/src/main/webapp/components/richMessage/list.xhtml
===================================================================
---
modules/tests/metamer/trunk/application/src/main/webapp/components/richMessage/list.xhtml 2011-05-06
18:23:48 UTC (rev 22478)
+++
modules/tests/metamer/trunk/application/src/main/webapp/components/richMessage/list.xhtml 2011-05-06
18:27:42 UTC (rev 22479)
@@ -38,7 +38,7 @@
<metamer:testPageLink id="jsr303" outcome="jsr303"
value="JSR-303 Bean Validation">
Page containing input with JSR-303 validator.
</metamer:testPageLink>
-
+
<metamer:testPageLink id="jsfValidator"
outcome="jsfValidator" value="Simple JSF Validation">
Page containing input with simple JSF validator.
</metamer:testPageLink>
Modified:
modules/tests/metamer/trunk/application/src/main/webapp/components/richMessages/csv.xhtml
===================================================================
---
modules/tests/metamer/trunk/application/src/main/webapp/components/richMessages/csv.xhtml 2011-05-06
18:23:48 UTC (rev 22478)
+++
modules/tests/metamer/trunk/application/src/main/webapp/components/richMessages/csv.xhtml 2011-05-06
18:27:42 UTC (rev 22479)
@@ -48,87 +48,87 @@
<ui:define name="component">
<script type="text/javascript">
function setCorrectValues() {
- $('input[id$=simpleInput1]').val('10');
- $('input[id$=simpleInput2]').val('10');
+ $('input[id$=simpleInput1]').val('10');
+ $('input[id$=simpleInput2]').val('10');
}
function setWrongValues() {
- $('input[id$=simpleInput1]').val('200');
- $('input[id$=simpleInput2]').val('200');
+ $('input[id$=simpleInput1]').val('200');
+ $('input[id$=simpleInput2]').val('200');
}
</script>
<input id="setCorrectValuesButton" type="button"
value="set correct values" onclick="setCorrectValues()"/>
<input id="setWrongValuesButton" type="button"
value="set wrong values" onclick="setWrongValues()"/>
-
+
<fieldset title="Msgs1 - with for attribute" >
- <legend>Messages1 - with 'for' attribute</legend>
- <rich:messages id="msgs1"
- for="#{richMessagesBean.attributes['for'].value}"
-
ajaxRendered="#{richMessagesBean.attributes['ajaxRendered'].value}"
-
keepTransient="#{richMessagesBean.attributes['keepTransient'].value}"
-
rendered="#{richMessagesBean.attributes['rendered'].value}"
-
showDetail="#{richMessagesBean.attributes['showDetail'].value}"
-
showSummary="#{richMessagesBean.attributes['showSummary'].value}"
- dir="#{richMessagesBean.attributes['dir'].value}"
-
lang="#{richMessagesBean.attributes['lang'].value}"
-
style="#{richMessagesBean.attributes['style'].value}"
-
styleClass="#{richMessagesBean.attributes['styleClass'].value}"
-
title="#{richMessagesBean.attributes['title'].value}"
-
onclick="#{richMessagesBean.attributes['onclick'].value}"
-
ondblclick="#{richMessagesBean.attributes['ondblclick'].value}"
-
onkeydown="#{richMessagesBean.attributes['onkeydown'].value}"
-
onkeypress="#{richMessagesBean.attributes['onkeypress'].value}"
-
onkeyup="#{richMessagesBean.attributes['onkeyup'].value}"
-
onmousedown="#{richMessagesBean.attributes['onmousedown'].value}"
-
onmousemove="#{richMessagesBean.attributes['onmousemove'].value}"
-
onmouseout="#{richMessagesBean.attributes['onmouseout'].value}"
-
onmouseover="#{richMessagesBean.attributes['onmouseover'].value}"
-
onmouseup="#{richMessagesBean.attributes['onmouseup'].value}"
- />
- </fieldset>
-
- <br/>
-
+ <legend>Messages1 - with 'for' attribute</legend>
+ <rich:messages id="msgs1"
+
for="#{richMessagesBean.attributes['for'].value}"
+
ajaxRendered="#{richMessagesBean.attributes['ajaxRendered'].value}"
+
keepTransient="#{richMessagesBean.attributes['keepTransient'].value}"
+
rendered="#{richMessagesBean.attributes['rendered'].value}"
+
showDetail="#{richMessagesBean.attributes['showDetail'].value}"
+
showSummary="#{richMessagesBean.attributes['showSummary'].value}"
+
dir="#{richMessagesBean.attributes['dir'].value}"
+
lang="#{richMessagesBean.attributes['lang'].value}"
+
style="#{richMessagesBean.attributes['style'].value}"
+
styleClass="#{richMessagesBean.attributes['styleClass'].value}"
+
title="#{richMessagesBean.attributes['title'].value}"
+
onclick="#{richMessagesBean.attributes['onclick'].value}"
+
ondblclick="#{richMessagesBean.attributes['ondblclick'].value}"
+
onkeydown="#{richMessagesBean.attributes['onkeydown'].value}"
+
onkeypress="#{richMessagesBean.attributes['onkeypress'].value}"
+
onkeyup="#{richMessagesBean.attributes['onkeyup'].value}"
+
onmousedown="#{richMessagesBean.attributes['onmousedown'].value}"
+
onmousemove="#{richMessagesBean.attributes['onmousemove'].value}"
+
onmouseout="#{richMessagesBean.attributes['onmouseout'].value}"
+
onmouseover="#{richMessagesBean.attributes['onmouseover'].value}"
+
onmouseup="#{richMessagesBean.attributes['onmouseup'].value}"
+ />
+ </fieldset>
+
+ <br/>
+
<fieldset title="Msgs2 - with globalOnly attribute">
- <legend>Messages2 - without 'for' but 'globalOnly'
attribute instead</legend>
- <rich:messages id="msgs2"
-
ajaxRendered="#{richMessagesBean.attributes['ajaxRendered'].value}"
-
globalOnly="#{richMessagesBean.attributes['globalOnly'].value}"
-
keepTransient="#{richMessagesBean.attributes['keepTransient'].value}"
-
rendered="#{richMessagesBean.attributes['rendered'].value}"
-
showDetail="#{richMessagesBean.attributes['showDetail'].value}"
-
showSummary="#{richMessagesBean.attributes['showSummary'].value}"
- dir="#{richMessagesBean.attributes['dir'].value}"
- lang="#{richMessagesBean.attributes['lang'].value}"
-
style="#{richMessagesBean.attributes['style'].value}"
-
styleClass="#{richMessagesBean.attributes['styleClass'].value}"
-
title="#{richMessagesBean.attributes['title'].value}"
-
onclick="#{richMessagesBean.attributes['onclick'].value}"
-
ondblclick="#{richMessagesBean.attributes['ondblclick'].value}"
-
onkeydown="#{richMessagesBean.attributes['onkeydown'].value}"
-
onkeypress="#{richMessagesBean.attributes['onkeypress'].value}"
-
onkeyup="#{richMessagesBean.attributes['onkeyup'].value}"
-
onmousedown="#{richMessagesBean.attributes['onmousedown'].value}"
-
onmousemove="#{richMessagesBean.attributes['onmousemove'].value}"
-
onmouseout="#{richMessagesBean.attributes['onmouseout'].value}"
-
onmouseover="#{richMessagesBean.attributes['onmouseover'].value}"
-
onmouseup="#{richMessagesBean.attributes['onmouseup'].value}"
- />
+ <legend>Messages2 - without 'for' but 'globalOnly'
attribute instead</legend>
+ <rich:messages id="msgs2"
+
ajaxRendered="#{richMessagesBean.attributes['ajaxRendered'].value}"
+
globalOnly="#{richMessagesBean.attributes['globalOnly'].value}"
+
keepTransient="#{richMessagesBean.attributes['keepTransient'].value}"
+
rendered="#{richMessagesBean.attributes['rendered'].value}"
+
showDetail="#{richMessagesBean.attributes['showDetail'].value}"
+
showSummary="#{richMessagesBean.attributes['showSummary'].value}"
+
dir="#{richMessagesBean.attributes['dir'].value}"
+
lang="#{richMessagesBean.attributes['lang'].value}"
+
style="#{richMessagesBean.attributes['style'].value}"
+
styleClass="#{richMessagesBean.attributes['styleClass'].value}"
+
title="#{richMessagesBean.attributes['title'].value}"
+
onclick="#{richMessagesBean.attributes['onclick'].value}"
+
ondblclick="#{richMessagesBean.attributes['ondblclick'].value}"
+
onkeydown="#{richMessagesBean.attributes['onkeydown'].value}"
+
onkeypress="#{richMessagesBean.attributes['onkeypress'].value}"
+
onkeyup="#{richMessagesBean.attributes['onkeyup'].value}"
+
onmousedown="#{richMessagesBean.attributes['onmousedown'].value}"
+
onmousemove="#{richMessagesBean.attributes['onmousemove'].value}"
+
onmouseout="#{richMessagesBean.attributes['onmouseout'].value}"
+
onmouseover="#{richMessagesBean.attributes['onmouseover'].value}"
+
onmouseup="#{richMessagesBean.attributes['onmouseup'].value}"
+ />
</fieldset>
-
+
<h:panelGrid columns="3">
- <h:outputLabel for="simpleInput1"
value="#{multipleValidationRulesBean.description}" />
+ <h:outputLabel for="simpleInput1"
value="#{multipleValidationRulesBean.description}" />
<h:inputText id="simpleInput1"
value="#{multipleValidationRulesBean.value}" label="Input 1"
- converter="#{multipleValidationRulesBean.converter}">
- <rich:validator />
- </h:inputText>
+
converter="#{multipleValidationRulesBean.converter}">
+ <rich:validator />
+ </h:inputText>
<rich:message id="simpleInputMsg1"
for="simpleInput1" ajaxRendered="true" />
-
+
<h:outputLabel for="simpleInput2"
value="#{multipleValidationRulesBean.description}" />
<h:inputText id="simpleInput2"
value="#{multipleValidationRulesBean.value}" label="Input 2"
- converter="#{multipleValidationRulesBean.converter}">
- <rich:validator />
+
converter="#{multipleValidationRulesBean.converter}">
+ <rich:validator />
</h:inputText>
<rich:message id="simpleInputMsg2"
for="simpleInput2" ajaxRendered="true" />
</h:panelGrid>
@@ -138,8 +138,8 @@
<h:commandButton id="hButton" value="h:commandButton"
style="margin-right: 10px;"/>
<a4j:commandButton id="a4jButton"
value="a4j:commandButton"/>
<a4j:commandButton id="generateMsgsBtn" value="Generate
Msgs"
- actionListener="#{richMessagesBean.generateFacesError}"
/>
-
+
actionListener="#{richMessagesBean.generateFacesError}" />
+
<br/>
<rich:messages id="msgs" />
Modified:
modules/tests/metamer/trunk/application/src/main/webapp/components/richMessages/jsfValidator.xhtml
===================================================================
---
modules/tests/metamer/trunk/application/src/main/webapp/components/richMessages/jsfValidator.xhtml 2011-05-06
18:23:48 UTC (rev 22478)
+++
modules/tests/metamer/trunk/application/src/main/webapp/components/richMessages/jsfValidator.xhtml 2011-05-06
18:27:42 UTC (rev 22479)
@@ -39,102 +39,102 @@
</f:viewParam>
</f:metadata>
</ui:define>
-
+
<ui:define name="component">
- <script type="text/javascript">
- function setCorrectValues() {
- $('input[id$=simpleInput1]').val('10');
- $('input[id$=simpleInput2]').val('10');
- }
+ <script type="text/javascript">
+ function setCorrectValues() {
+ $('input[id$=simpleInput1]').val('10');
+ $('input[id$=simpleInput2]').val('10');
+ }
- function setWrongValues() {
- $('input[id$=simpleInput1]').val('200');
- $('input[id$=simpleInput2]').val('200');
- }
+ function setWrongValues() {
+ $('input[id$=simpleInput1]').val('200');
+ $('input[id$=simpleInput2]').val('200');
+ }
</script>
<input id="setCorrectValuesButton" type="button"
value="set correct values" onclick="setCorrectValues()"/>
<input id="setWrongValuesButton" type="button"
value="set wrong values" onclick="setWrongValues()"/>
-
+
<fieldset title="Msgs1 - with for attribute" >
- <legend>Messages1 - with 'for' attribute</legend>
- <rich:messages id="msgs1"
- for="#{richMessagesBean.attributes['for'].value}"
-
ajaxRendered="#{richMessagesBean.attributes['ajaxRendered'].value}"
-
keepTransient="#{richMessagesBean.attributes['keepTransient'].value}"
-
rendered="#{richMessagesBean.attributes['rendered'].value}"
-
showDetail="#{richMessagesBean.attributes['showDetail'].value}"
-
showSummary="#{richMessagesBean.attributes['showSummary'].value}"
- dir="#{richMessagesBean.attributes['dir'].value}"
-
lang="#{richMessagesBean.attributes['lang'].value}"
-
style="#{richMessagesBean.attributes['style'].value}"
-
styleClass="#{richMessagesBean.attributes['styleClass'].value}"
-
title="#{richMessagesBean.attributes['title'].value}"
-
onclick="#{richMessagesBean.attributes['onclick'].value}"
-
ondblclick="#{richMessagesBean.attributes['ondblclick'].value}"
-
onkeydown="#{richMessagesBean.attributes['onkeydown'].value}"
-
onkeypress="#{richMessagesBean.attributes['onkeypress'].value}"
-
onkeyup="#{richMessagesBean.attributes['onkeyup'].value}"
-
onmousedown="#{richMessagesBean.attributes['onmousedown'].value}"
-
onmousemove="#{richMessagesBean.attributes['onmousemove'].value}"
-
onmouseout="#{richMessagesBean.attributes['onmouseout'].value}"
-
onmouseover="#{richMessagesBean.attributes['onmouseover'].value}"
-
onmouseup="#{richMessagesBean.attributes['onmouseup'].value}"
- />
- </fieldset>
-
- <br/>
-
+ <legend>Messages1 - with 'for' attribute</legend>
+ <rich:messages id="msgs1"
+
for="#{richMessagesBean.attributes['for'].value}"
+
ajaxRendered="#{richMessagesBean.attributes['ajaxRendered'].value}"
+
keepTransient="#{richMessagesBean.attributes['keepTransient'].value}"
+
rendered="#{richMessagesBean.attributes['rendered'].value}"
+
showDetail="#{richMessagesBean.attributes['showDetail'].value}"
+
showSummary="#{richMessagesBean.attributes['showSummary'].value}"
+
dir="#{richMessagesBean.attributes['dir'].value}"
+
lang="#{richMessagesBean.attributes['lang'].value}"
+
style="#{richMessagesBean.attributes['style'].value}"
+
styleClass="#{richMessagesBean.attributes['styleClass'].value}"
+
title="#{richMessagesBean.attributes['title'].value}"
+
onclick="#{richMessagesBean.attributes['onclick'].value}"
+
ondblclick="#{richMessagesBean.attributes['ondblclick'].value}"
+
onkeydown="#{richMessagesBean.attributes['onkeydown'].value}"
+
onkeypress="#{richMessagesBean.attributes['onkeypress'].value}"
+
onkeyup="#{richMessagesBean.attributes['onkeyup'].value}"
+
onmousedown="#{richMessagesBean.attributes['onmousedown'].value}"
+
onmousemove="#{richMessagesBean.attributes['onmousemove'].value}"
+
onmouseout="#{richMessagesBean.attributes['onmouseout'].value}"
+
onmouseover="#{richMessagesBean.attributes['onmouseover'].value}"
+
onmouseup="#{richMessagesBean.attributes['onmouseup'].value}"
+ />
+ </fieldset>
+
+ <br/>
+
<fieldset title="Msgs2 - with globalOnly attribute">
- <legend>Messages2 - without 'for' but 'globalOnly'
attribute instead</legend>
- <rich:messages id="msgs2"
-
ajaxRendered="#{richMessagesBean.attributes['ajaxRendered'].value}"
-
globalOnly="#{richMessagesBean.attributes['globalOnly'].value}"
-
keepTransient="#{richMessagesBean.attributes['keepTransient'].value}"
-
rendered="#{richMessagesBean.attributes['rendered'].value}"
-
showDetail="#{richMessagesBean.attributes['showDetail'].value}"
-
showSummary="#{richMessagesBean.attributes['showSummary'].value}"
- dir="#{richMessagesBean.attributes['dir'].value}"
- lang="#{richMessagesBean.attributes['lang'].value}"
-
style="#{richMessagesBean.attributes['style'].value}"
-
styleClass="#{richMessagesBean.attributes['styleClass'].value}"
-
title="#{richMessagesBean.attributes['title'].value}"
-
onclick="#{richMessagesBean.attributes['onclick'].value}"
-
ondblclick="#{richMessagesBean.attributes['ondblclick'].value}"
-
onkeydown="#{richMessagesBean.attributes['onkeydown'].value}"
-
onkeypress="#{richMessagesBean.attributes['onkeypress'].value}"
-
onkeyup="#{richMessagesBean.attributes['onkeyup'].value}"
-
onmousedown="#{richMessagesBean.attributes['onmousedown'].value}"
-
onmousemove="#{richMessagesBean.attributes['onmousemove'].value}"
-
onmouseout="#{richMessagesBean.attributes['onmouseout'].value}"
-
onmouseover="#{richMessagesBean.attributes['onmouseover'].value}"
-
onmouseup="#{richMessagesBean.attributes['onmouseup'].value}"
- />
+ <legend>Messages2 - without 'for' but 'globalOnly'
attribute instead</legend>
+ <rich:messages id="msgs2"
+
ajaxRendered="#{richMessagesBean.attributes['ajaxRendered'].value}"
+
globalOnly="#{richMessagesBean.attributes['globalOnly'].value}"
+
keepTransient="#{richMessagesBean.attributes['keepTransient'].value}"
+
rendered="#{richMessagesBean.attributes['rendered'].value}"
+
showDetail="#{richMessagesBean.attributes['showDetail'].value}"
+
showSummary="#{richMessagesBean.attributes['showSummary'].value}"
+
dir="#{richMessagesBean.attributes['dir'].value}"
+
lang="#{richMessagesBean.attributes['lang'].value}"
+
style="#{richMessagesBean.attributes['style'].value}"
+
styleClass="#{richMessagesBean.attributes['styleClass'].value}"
+
title="#{richMessagesBean.attributes['title'].value}"
+
onclick="#{richMessagesBean.attributes['onclick'].value}"
+
ondblclick="#{richMessagesBean.attributes['ondblclick'].value}"
+
onkeydown="#{richMessagesBean.attributes['onkeydown'].value}"
+
onkeypress="#{richMessagesBean.attributes['onkeypress'].value}"
+
onkeyup="#{richMessagesBean.attributes['onkeyup'].value}"
+
onmousedown="#{richMessagesBean.attributes['onmousedown'].value}"
+
onmousemove="#{richMessagesBean.attributes['onmousemove'].value}"
+
onmouseout="#{richMessagesBean.attributes['onmouseout'].value}"
+
onmouseover="#{richMessagesBean.attributes['onmouseover'].value}"
+
onmouseup="#{richMessagesBean.attributes['onmouseup'].value}"
+ />
</fieldset>
-
+
<h:panelGrid columns="3">
- <h:outputLabel for="simpleInput1"
value="#{multipleValidationRulesBean.description}" />
+ <h:outputLabel for="simpleInput1"
value="#{multipleValidationRulesBean.description}" />
<h:inputText id="simpleInput1"
value="#{richMessagesBean.simpleInput1}" label="Input 1" >
- <f:validateLongRange minimum="5" maximum="150"
/>
- <f:validateLength maximum="2" />
+ <f:validateLongRange minimum="5" maximum="150"
/>
+ <f:validateLength maximum="2" />
</h:inputText>
<rich:message id="simpleInputMsg1"
ajaxRendered="true" for="simpleInput1" />
-
- <h:outputLabel for="simpleInput2"
value="#{multipleValidationRulesBean.description}" />
+
+ <h:outputLabel for="simpleInput2"
value="#{multipleValidationRulesBean.description}" />
<h:inputText id="simpleInput2"
value="#{richMessagesBean.simpleInput2}" label="Input 2" >
- <f:validateLongRange minimum="5" maximum="150"
/>
- <f:validateLength maximum="2" />
+ <f:validateLongRange minimum="5" maximum="150"
/>
+ <f:validateLength maximum="2" />
</h:inputText>
<rich:message id="simpleInputMsg2"
ajaxRendered="true" for="simpleInput2" />
</h:panelGrid>
-
+
<br/>
-
+
<h:commandButton id="hButton" value="h:commandButton"
style="margin-right: 10px;"/>
<a4j:commandButton id="a4jButton"
value="a4j:commandButton"/>
<a4j:commandButton id="generateMsgsBtn" value="Generate
Msgs"
- actionListener="#{richMessagesBean.generateFacesError}"
/>
-
+
actionListener="#{richMessagesBean.generateFacesError}" />
+
<br/>
<rich:messages id="msgs" />
Modified:
modules/tests/metamer/trunk/application/src/main/webapp/components/richMessages/jsr303.xhtml
===================================================================
---
modules/tests/metamer/trunk/application/src/main/webapp/components/richMessages/jsr303.xhtml 2011-05-06
18:23:48 UTC (rev 22478)
+++
modules/tests/metamer/trunk/application/src/main/webapp/components/richMessages/jsr303.xhtml 2011-05-06
18:27:42 UTC (rev 22479)
@@ -48,87 +48,87 @@
<ui:define name="component">
<script type="text/javascript">
function setCorrectValues() {
- $('input[id$=simpleInput1]').val('10');
- $('input[id$=simpleInput2]').val('10');
+ $('input[id$=simpleInput1]').val('10');
+ $('input[id$=simpleInput2]').val('10');
}
function setWrongValues() {
- $('input[id$=simpleInput1]').val('200');
- $('input[id$=simpleInput2]').val('200');
+ $('input[id$=simpleInput1]').val('200');
+ $('input[id$=simpleInput2]').val('200');
}
</script>
<input id="setCorrectValuesButton" type="button"
value="set correct values" onclick="setCorrectValues()"/>
<input id="setWrongValuesButton" type="button"
value="set wrong values" onclick="setWrongValues()"/>
-
+
<br/>
- <fieldset title="Msgs1 - with for attribute" >
- <legend>Messages1 - with 'for' attribute</legend>
- <rich:messages id="msgs1"
- for="#{richMessagesBean.attributes['for'].value}"
-
ajaxRendered="#{richMessagesBean.attributes['ajaxRendered'].value}"
-
keepTransient="#{richMessagesBean.attributes['keepTransient'].value}"
-
rendered="#{richMessagesBean.attributes['rendered'].value}"
-
showDetail="#{richMessagesBean.attributes['showDetail'].value}"
-
showSummary="#{richMessagesBean.attributes['showSummary'].value}"
- dir="#{richMessagesBean.attributes['dir'].value}"
-
lang="#{richMessagesBean.attributes['lang'].value}"
-
style="#{richMessagesBean.attributes['style'].value}"
-
styleClass="#{richMessagesBean.attributes['styleClass'].value}"
-
title="#{richMessagesBean.attributes['title'].value}"
-
onclick="#{richMessagesBean.attributes['onclick'].value}"
-
ondblclick="#{richMessagesBean.attributes['ondblclick'].value}"
-
onkeydown="#{richMessagesBean.attributes['onkeydown'].value}"
-
onkeypress="#{richMessagesBean.attributes['onkeypress'].value}"
-
onkeyup="#{richMessagesBean.attributes['onkeyup'].value}"
-
onmousedown="#{richMessagesBean.attributes['onmousedown'].value}"
-
onmousemove="#{richMessagesBean.attributes['onmousemove'].value}"
-
onmouseout="#{richMessagesBean.attributes['onmouseout'].value}"
-
onmouseover="#{richMessagesBean.attributes['onmouseover'].value}"
-
onmouseup="#{richMessagesBean.attributes['onmouseup'].value}"
- />
- </fieldset>
-
- <br/>
-
+ <fieldset title="Msgs1 - with for attribute" >
+ <legend>Messages1 - with 'for' attribute</legend>
+ <rich:messages id="msgs1"
+
for="#{richMessagesBean.attributes['for'].value}"
+
ajaxRendered="#{richMessagesBean.attributes['ajaxRendered'].value}"
+
keepTransient="#{richMessagesBean.attributes['keepTransient'].value}"
+
rendered="#{richMessagesBean.attributes['rendered'].value}"
+
showDetail="#{richMessagesBean.attributes['showDetail'].value}"
+
showSummary="#{richMessagesBean.attributes['showSummary'].value}"
+
dir="#{richMessagesBean.attributes['dir'].value}"
+
lang="#{richMessagesBean.attributes['lang'].value}"
+
style="#{richMessagesBean.attributes['style'].value}"
+
styleClass="#{richMessagesBean.attributes['styleClass'].value}"
+
title="#{richMessagesBean.attributes['title'].value}"
+
onclick="#{richMessagesBean.attributes['onclick'].value}"
+
ondblclick="#{richMessagesBean.attributes['ondblclick'].value}"
+
onkeydown="#{richMessagesBean.attributes['onkeydown'].value}"
+
onkeypress="#{richMessagesBean.attributes['onkeypress'].value}"
+
onkeyup="#{richMessagesBean.attributes['onkeyup'].value}"
+
onmousedown="#{richMessagesBean.attributes['onmousedown'].value}"
+
onmousemove="#{richMessagesBean.attributes['onmousemove'].value}"
+
onmouseout="#{richMessagesBean.attributes['onmouseout'].value}"
+
onmouseover="#{richMessagesBean.attributes['onmouseover'].value}"
+
onmouseup="#{richMessagesBean.attributes['onmouseup'].value}"
+ />
+ </fieldset>
+
+ <br/>
+
<fieldset title="Msgs2 - with globalOnly attribute">
- <legend>Messages2 - without 'for' but 'globalOnly'
attribute instead</legend>
- <rich:messages id="msgs2"
-
ajaxRendered="#{richMessagesBean.attributes['ajaxRendered'].value}"
-
globalOnly="#{richMessagesBean.attributes['globalOnly'].value}"
-
keepTransient="#{richMessagesBean.attributes['keepTransient'].value}"
-
rendered="#{richMessagesBean.attributes['rendered'].value}"
-
showDetail="#{richMessagesBean.attributes['showDetail'].value}"
-
showSummary="#{richMessagesBean.attributes['showSummary'].value}"
- dir="#{richMessagesBean.attributes['dir'].value}"
- lang="#{richMessagesBean.attributes['lang'].value}"
-
style="#{richMessagesBean.attributes['style'].value}"
-
styleClass="#{richMessagesBean.attributes['styleClass'].value}"
-
title="#{richMessagesBean.attributes['title'].value}"
-
onclick="#{richMessagesBean.attributes['onclick'].value}"
-
ondblclick="#{richMessagesBean.attributes['ondblclick'].value}"
-
onkeydown="#{richMessagesBean.attributes['onkeydown'].value}"
-
onkeypress="#{richMessagesBean.attributes['onkeypress'].value}"
-
onkeyup="#{richMessagesBean.attributes['onkeyup'].value}"
-
onmousedown="#{richMessagesBean.attributes['onmousedown'].value}"
-
onmousemove="#{richMessagesBean.attributes['onmousemove'].value}"
-
onmouseout="#{richMessagesBean.attributes['onmouseout'].value}"
-
onmouseover="#{richMessagesBean.attributes['onmouseover'].value}"
-
onmouseup="#{richMessagesBean.attributes['onmouseup'].value}"
- />
+ <legend>Messages2 - without 'for' but 'globalOnly'
attribute instead</legend>
+ <rich:messages id="msgs2"
+
ajaxRendered="#{richMessagesBean.attributes['ajaxRendered'].value}"
+
globalOnly="#{richMessagesBean.attributes['globalOnly'].value}"
+
keepTransient="#{richMessagesBean.attributes['keepTransient'].value}"
+
rendered="#{richMessagesBean.attributes['rendered'].value}"
+
showDetail="#{richMessagesBean.attributes['showDetail'].value}"
+
showSummary="#{richMessagesBean.attributes['showSummary'].value}"
+
dir="#{richMessagesBean.attributes['dir'].value}"
+
lang="#{richMessagesBean.attributes['lang'].value}"
+
style="#{richMessagesBean.attributes['style'].value}"
+
styleClass="#{richMessagesBean.attributes['styleClass'].value}"
+
title="#{richMessagesBean.attributes['title'].value}"
+
onclick="#{richMessagesBean.attributes['onclick'].value}"
+
ondblclick="#{richMessagesBean.attributes['ondblclick'].value}"
+
onkeydown="#{richMessagesBean.attributes['onkeydown'].value}"
+
onkeypress="#{richMessagesBean.attributes['onkeypress'].value}"
+
onkeyup="#{richMessagesBean.attributes['onkeyup'].value}"
+
onmousedown="#{richMessagesBean.attributes['onmousedown'].value}"
+
onmousemove="#{richMessagesBean.attributes['onmousemove'].value}"
+
onmouseout="#{richMessagesBean.attributes['onmouseout'].value}"
+
onmouseover="#{richMessagesBean.attributes['onmouseover'].value}"
+
onmouseup="#{richMessagesBean.attributes['onmouseup'].value}"
+ />
</fieldset>
-
+
<h:panelGrid columns="3">
- <h:outputLabel for="simpleInput1"
value="#{multipleValidationRulesBean.description}" />
- <h:inputText id="simpleInput1"
value="#{multipleValidationRulesBean.value}" label="Input 1"
- converter="#{multipleValidationRulesBean.converter}" />
- <rich:message id="simpleInputMsg1" ajaxRendered="true"
for="simpleInput1" />
-
- <h:outputLabel for="simpleInput2"
value="#{multipleValidationRulesBean.description}" />
- <h:inputText id="simpleInput2"
value="#{multipleValidationRulesBean.value}" label="Input 2"
- converter="#{multipleValidationRulesBean.converter}" />
- <rich:message id="simpleInputMsg2"
ajaxRendered="true" for="simpleInput2" />
+ <h:outputLabel for="simpleInput1"
value="#{multipleValidationRulesBean.description}" />
+ <h:inputText id="simpleInput1"
value="#{multipleValidationRulesBean.value}" label="Input 1"
+
converter="#{multipleValidationRulesBean.converter}" />
+ <rich:message id="simpleInputMsg1"
ajaxRendered="true" for="simpleInput1" />
+
+ <h:outputLabel for="simpleInput2"
value="#{multipleValidationRulesBean.description}" />
+ <h:inputText id="simpleInput2"
value="#{multipleValidationRulesBean.value}" label="Input 2"
+
converter="#{multipleValidationRulesBean.converter}" />
+ <rich:message id="simpleInputMsg2"
ajaxRendered="true" for="simpleInput2" />
</h:panelGrid>
<br/>
@@ -136,15 +136,15 @@
<h:commandButton id="hButton" value="h:commandButton"
style="margin-right: 10px;"/>
<a4j:commandButton id="a4jButton"
value="a4j:commandButton"/>
<a4j:commandButton id="generateMsgsBtn" value="Generate
Msgs"
- actionListener="#{richMessagesBean.generateFacesError}"
/>
-
+
actionListener="#{richMessagesBean.generateFacesError}" />
+
<br/>
<rich:messages id="msgs" />
</ui:define>
<ui:define name="outOfTemplateAfter">
- <metamer:attributes value="#{richMessagesBean.attributes}"
id="attributes"/>
+ <metamer:attributes value="#{richMessagesBean.attributes}"
id="attributes"/>
</ui:define>
</ui:composition>
Modified:
modules/tests/metamer/trunk/application/src/main/webapp/components/richMessages/list.xhtml
===================================================================
---
modules/tests/metamer/trunk/application/src/main/webapp/components/richMessages/list.xhtml 2011-05-06
18:23:48 UTC (rev 22478)
+++
modules/tests/metamer/trunk/application/src/main/webapp/components/richMessages/list.xhtml 2011-05-06
18:27:42 UTC (rev 22479)
@@ -38,7 +38,7 @@
<metamer:testPageLink id="jsr303" outcome="jsr303"
value="JSR-303 Bean Validation">
Page containing input with JSR-303 validator.
</metamer:testPageLink>
-
+
<metamer:testPageLink id="jsfValidator"
outcome="jsfValidator" value="Simple JSF Validation">
Page containing input with simple JSF validator.
</metamer:testPageLink>
Modified:
modules/tests/metamer/trunk/ftest-source/src/main/java/org/richfaces/tests/metamer/ftest/richMessage/AbstractRichMessageTest.java
===================================================================
---
modules/tests/metamer/trunk/ftest-source/src/main/java/org/richfaces/tests/metamer/ftest/richMessage/AbstractRichMessageTest.java 2011-05-06
18:23:48 UTC (rev 22478)
+++
modules/tests/metamer/trunk/ftest-source/src/main/java/org/richfaces/tests/metamer/ftest/richMessage/AbstractRichMessageTest.java 2011-05-06
18:27:42 UTC (rev 22479)
@@ -45,22 +45,19 @@
* @version $Revision$
*/
public abstract class AbstractRichMessageTest extends AbstractMetamerTest {
-
+
private static Logger logger =
LoggerFactory.getLogger(AbstractRichMessageTest.class);
-
- protected RichMessageComponentAttributes attributes = new
RichMessageComponentAttributes();
-
+ protected RichMessageComponentAttributes attributes = new
RichMessageComponentAttributes();
// controls
protected JQueryLocator wrongValuesBtn =
pjq("input[type=button][id$=setWrongValuesButton]");
protected JQueryLocator correctValuesBtn =
pjq("input[type=button][id$=setCorrectValuesButton]");
protected JQueryLocator hCommandBtn = pjq("input[id$=hButton]");
protected JQueryLocator a4jCommandBtn = pjq("input[id$=a4jButton]");
-
// component's locators
protected static JQueryLocator message4Input1 =
pjq("span[id$=simpleInputMsg1]");
protected static JQueryLocator message4Input2 =
pjq("span[id$=simpleInputMsg2]");
protected static JQueryLocator messages = pjq("span[id$=msgs]");
-
+
/**
* Because of message and messages have many attributes very similar,
* this method helps test method distinguish between metamer
@@ -70,31 +67,34 @@
* @return ElementLocator for container with rich:message(s)
*/
public abstract JQueryLocator getTestElemLocator();
-
+
/**
* This method implementation specific for rich:message and rich:messages
* help distinguish between them, and return correct locator
* @return JQueryLocator for container with summary or detail of message(s)
component
*/
public abstract JQueryLocator getSummaryElemLocator();
+
public abstract JQueryLocator getDetailElemLocator();
-
- public void testHtmlAttribute(ElementLocator<?> element, RichMessageAttributes
attribute, String value) {
-
+
+ public void testHtmlAttribute(ElementLocator<?> element, RichMessageAttributes
attribute, String value) {
+
AttributeLocator<?> attr = element.getAttribute(new
Attribute(attribute.toString()));
selenium.type(pjq("input[id$=" + attribute + "Input]"),
value);
- if (logger.isDebugEnabled()) logger.debug(" ######## attribute = " +
attribute);
-
+ if (logger.isDebugEnabled()) {
+ logger.debug(" ######## attribute = " + attribute);
+ }
+
selenium.waitForPageToLoad();
-
+
// generate validation message
generateValidationMessages(false);
assertTrue(selenium.getAttribute(attr).contains(value), "Attribute " +
attribute + " should contain \"" + value
+ "\".");
}
-
+
/**
* A helper method for testing javascripts events. It sets
alert('testedevent') to the input field for given event
* and fires the event. Then it checks the message in the alert dialog.
@@ -110,7 +110,7 @@
String value = "metamerEvents += \"" + event.getEventName() +
" \"";
guardHttp(selenium).type(eventInput, value);
-
+
// generate validation messages
generateValidationMessages(false);
@@ -119,7 +119,7 @@
waitGui.failWith("Attribute on" + event.getEventName() + " does
not work correctly").until(
new EventFiredCondition(event));
}
-
+
/**
* A helper method for testing attribute "class". It sets
"metamer-ftest-class" to the input field and checks that
* it was changed on the page.
@@ -134,14 +134,14 @@
final String styleClass = "metamer-ftest-class";
selenium.type(ref(attributesRoot, "input[id$=" + attribute +
"Input]"), styleClass);
selenium.waitForPageToLoad();
-
+
generateValidationMessages(false);
JQueryLocator elementWhichHasntThatClass = jq(element.getRawLocator() +
":not(.{0})").format(styleClass);
assertTrue(selenium.isElementPresent(element));
assertFalse(selenium.isElementPresent(elementWhichHasntThatClass));
}
-
+
/**
* Set wrong values into appropriate inputs and generate validation
* messages by submitting form.
@@ -151,9 +151,9 @@
*
* @param Boolean <b>byAjax</b> - use to choose submit button type used
to submit form
*/
- public void generateValidationMessages(Boolean byAjax) {
+ public void generateValidationMessages(Boolean byAjax) {
waitModel.until(elementPresent.locator(wrongValuesBtn));
- selenium.click(wrongValuesBtn);
+ selenium.click(wrongValuesBtn);
if (byAjax) {
waitModel.until(elementPresent.locator(a4jCommandBtn));
selenium.click(a4jCommandBtn);
@@ -163,137 +163,133 @@
selenium.waitForPageToLoad();
}
}
-
+
protected void waitForAttribute(RichMessageAttributes attr) {
- waitGui.until(attributeEquals
- .locator(getTestElemLocator().getAttribute(new Attribute(attr.toString())))
- .text(attr.toString()));
+ waitGui.until(attributeEquals.locator(getTestElemLocator().getAttribute(new
Attribute(attr.toString()))).text(attr.toString()));
}
-
+
// ==================== test methods ====================
-
/**
* ajaxRendered attribute change behavior: messages are displayed
* after action performed by a4j:button (not only by h:command*)
*/
- public void testAjaxRendered(){
+ public void testAjaxRendered() {
// with set to false, element with id$=simpleInputMsg shouldn't appear
-
+
// by default is ajaxRendered set to true
generateValidationMessages(true);
waitGui.until(elementPresent.locator(getTestElemLocator()));
-
+
// then disable ajaxRendered
attributes.setAjaxRendered(Boolean.FALSE);
generateValidationMessages(true);
- waitGui.until(isNotDisplayed.locator(getTestElemLocator()));
+ waitGui.until(isNotDisplayed.locator(getTestElemLocator()));
}
-
+
/**
* This attribute could disable displaying message
*/
- public void testRendered(){
+ public void testRendered() {
// with set to false, element with id$=simpleInputMsg shouldn't appear
-
+
attributes.setRendered(Boolean.TRUE);
generateValidationMessages(false);
waitGui.until(elementPresent.locator(getTestElemLocator()));
-
+
// now disable rendering message
attributes.setRendered(Boolean.FALSE);
generateValidationMessages(false);
waitGui.until(isNotDisplayed.locator(getTestElemLocator()));
}
-
+
/**
* Attribute for managing display Summary
*/
public void testShowSummary() {
// span with class=rf-msg-sum should appear when set to true
-
+
attributes.setShowSummary(Boolean.TRUE);
generateValidationMessages(false);
waitModel.until(elementPresent.locator(getSummaryElemLocator()));
-
+
attributes.setShowSummary(Boolean.FALSE);
generateValidationMessages(false);
waitGui.until(isNotDisplayed.locator(getSummaryElemLocator()));
}
-
+
/**
* Attribute for managing display Detail
*/
public void testShowDetail() {
// span with class=rf-msg-det should appear when set to true
-
+
attributes.setShowDetail(Boolean.TRUE);
generateValidationMessages(false);
waitGui.until(elementPresent.locator(getDetailElemLocator()));
-
+
attributes.setShowDetail(Boolean.FALSE);
generateValidationMessages(false);
waitGui.until(isNotDisplayed.locator(getDetailElemLocator()));
}
-
+
public void testTitle() {
testHtmlAttribute(getTestElemLocator(), RichMessageAttributes.TITLE, "Title
test");
}
-
- public void testDir(){
+
+ public void testDir() {
testHtmlAttribute(getTestElemLocator(), RichMessageAttributes.DIR,
"rtl");
}
-
- public void testLang(){
+
+ public void testLang() {
testHtmlAttribute(getTestElemLocator(), RichMessageAttributes.LANG,
"US.en");
}
-
- public void testStyle(){
+
+ public void testStyle() {
testHtmlAttribute(getTestElemLocator(), RichMessageAttributes.STYLE, "color:
blue;");
}
-
+
public void testStyleClass() {
// attribute styleClass is propagated as class attribute in target HTML element
testStyleClass(getTestElemLocator(),
RichMessageAttributes.STYLE_CLASS.toString());
}
-
+
public void testOnClick() {
testFireEvent(Event.CLICK, getTestElemLocator());
}
-
+
public void testOnDblClick() {
testFireEvent(Event.DBLCLICK, getTestElemLocator());
}
-
+
public void testOnKeyDown() {
testFireEvent(Event.KEYDOWN, getTestElemLocator());
}
-
+
public void testOnKeyPress() {
testFireEvent(Event.KEYPRESS, getTestElemLocator());
}
-
+
public void testOnKeyUp() {
testFireEvent(Event.KEYUP, getTestElemLocator());
}
-
+
public void testOnMouseDown() {
testFireEvent(Event.MOUSEDOWN, getTestElemLocator());
}
-
+
public void testOnMouseMove() {
testFireEvent(Event.MOUSEMOVE, getTestElemLocator());
}
-
+
public void testOnMouseOut() {
testFireEvent(Event.MOUSEOUT, getTestElemLocator());
}
-
+
public void testOnMouseOver() {
testFireEvent(Event.MOUSEOVER, getTestElemLocator());
}
-
+
public void testOnMouseUp() {
testFireEvent(Event.MOUSEUP, getTestElemLocator());
}
-
}
Modified:
modules/tests/metamer/trunk/ftest-source/src/main/java/org/richfaces/tests/metamer/ftest/richMessage/RichMessageAttributes.java
===================================================================
---
modules/tests/metamer/trunk/ftest-source/src/main/java/org/richfaces/tests/metamer/ftest/richMessage/RichMessageAttributes.java 2011-05-06
18:23:48 UTC (rev 22478)
+++
modules/tests/metamer/trunk/ftest-source/src/main/java/org/richfaces/tests/metamer/ftest/richMessage/RichMessageAttributes.java 2011-05-06
18:27:42 UTC (rev 22479)
@@ -22,7 +22,6 @@
package org.richfaces.tests.metamer.ftest.richMessage;
/**
- *
* This should be enum for all know attributes.
* Need to implement an "retriever" method to get
* values from key such as "class" by "_class" key
@@ -31,24 +30,24 @@
* @version $Revision$
*/
public enum RichMessageAttributes {
- AJAX_RENDERED ("ajaxRendered"),
- RENDERED ("rendered"),
- DIR ("dir"),
- FOR ("for"),
- LANG ("lang"),
- TITLE ("title"),
- CLASS ("class"),
- STYLE ("style"),
- STYLE_CLASS ("styleClass"),
- ;
-
- private String value;
- RichMessageAttributes(String val){
+
+ AJAX_RENDERED("ajaxRendered"),
+ RENDERED("rendered"),
+ DIR("dir"),
+ FOR("for"),
+ LANG("lang"),
+ TITLE("title"),
+ CLASS("class"),
+ STYLE("style"),
+ STYLE_CLASS("styleClass");
+ private String value;
+
+ RichMessageAttributes(String val) {
this.value = val;
}
@Override
- public String toString() {
+ public String toString() {
return value;
- }
-}
\ No newline at end of file
+ }
+}
Modified:
modules/tests/metamer/trunk/ftest-source/src/main/java/org/richfaces/tests/metamer/ftest/richMessage/RichMessageComponentAttributes.java
===================================================================
---
modules/tests/metamer/trunk/ftest-source/src/main/java/org/richfaces/tests/metamer/ftest/richMessage/RichMessageComponentAttributes.java 2011-05-06
18:23:48 UTC (rev 22478)
+++
modules/tests/metamer/trunk/ftest-source/src/main/java/org/richfaces/tests/metamer/ftest/richMessage/RichMessageComponentAttributes.java 2011-05-06
18:27:42 UTC (rev 22479)
@@ -30,29 +30,28 @@
* @version $Revision$
*/
public class RichMessageComponentAttributes extends AbstractComponentAttributes {
-
+
public void setRendered(Boolean rendered) {
setProperty("rendered", rendered);
}
-
+
public void setAjaxRendered(Boolean rendered) {
setProperty("ajaxRendered", rendered);
}
-
- public void setShowDetail(Boolean showDetail){
+
+ public void setShowDetail(Boolean showDetail) {
setProperty("showDetail", showDetail);
}
-
- public void setShowSummary(Boolean showSummary){
+
+ public void setShowSummary(Boolean showSummary) {
setProperty("showSummary", showSummary);
}
-
- public void setFor(String forAttribute){
+
+ public void setFor(String forAttribute) {
setProperty("for", forAttribute);
}
-
- public void setGlobalOnly(Boolean globalOnly){
+
+ public void setGlobalOnly(Boolean globalOnly) {
setProperty("globalOnly", globalOnly);
}
-
}
Modified:
modules/tests/metamer/trunk/ftest-source/src/main/java/org/richfaces/tests/metamer/ftest/richMessage/RichMessageTest.java
===================================================================
---
modules/tests/metamer/trunk/ftest-source/src/main/java/org/richfaces/tests/metamer/ftest/richMessage/RichMessageTest.java 2011-05-06
18:23:48 UTC (rev 22478)
+++
modules/tests/metamer/trunk/ftest-source/src/main/java/org/richfaces/tests/metamer/ftest/richMessage/RichMessageTest.java 2011-05-06
18:27:42 UTC (rev 22479)
@@ -25,7 +25,6 @@
import org.jboss.test.selenium.locator.JQueryLocator;
-
/**
* Abstract class with list of tests appropriate for rich:message component
*
@@ -33,31 +32,29 @@
* @version $Revision$
*/
public abstract class RichMessageTest extends AbstractRichMessageTest {
-
+
// locator for main rich:message component (tested element)
protected static JQueryLocator mainMessage =
pjq("span[id$=simpleInputMsg]");
-
protected JQueryLocator summary =
getTestElemLocator().getDescendant(jq("span.rf-msg-sum"));
protected JQueryLocator detail =
getTestElemLocator().getDescendant(jq("span.rf-msg-det"));
-
+
/**
* Attribute 'for' change behavior: only messages bound to element with
* id specified in 'for' should be displayed
*/
public void testFor() {
-
+
// firstly, remove value from attribute for and generate message
attributes.setFor("");
-
- generateValidationMessages(false);
+
+ generateValidationMessages(false);
// assertFalse(selenium.isElementPresent(getTestElemLocator()));
waitGui.until(isNotDisplayed.locator(getTestElemLocator()));
-
+
// now set for attribute back to "simpleInput2"
attributes.setFor("simpleInput2");
-
+
generateValidationMessages(false);
waitGui.until(elementPresent.locator(getTestElemLocator()));
}
-
}
Modified:
modules/tests/metamer/trunk/ftest-source/src/main/java/org/richfaces/tests/metamer/ftest/richMessage/TestRichMessageCSV.java
===================================================================
---
modules/tests/metamer/trunk/ftest-source/src/main/java/org/richfaces/tests/metamer/ftest/richMessage/TestRichMessageCSV.java 2011-05-06
18:23:48 UTC (rev 22478)
+++
modules/tests/metamer/trunk/ftest-source/src/main/java/org/richfaces/tests/metamer/ftest/richMessage/TestRichMessageCSV.java 2011-05-06
18:27:42 UTC (rev 22479)
@@ -25,7 +25,6 @@
import java.net.URL;
-import org.jboss.test.selenium.dom.Event;
import org.jboss.test.selenium.locator.JQueryLocator;
import org.testng.annotations.Test;
@@ -36,7 +35,7 @@
* @version $Revision$
*/
public class TestRichMessageCSV extends RichMessageTest {
-
+
@Override
public URL getTestUrl() {
return buildUrl(contextPath,
"faces/components/richMessage/csv.xhtml");
@@ -56,104 +55,103 @@
public JQueryLocator getDetailElemLocator() {
return detail;
}
-
+
// list of called test methods
-
@Test
- public void testFor(){
+ public void testFor() {
super.testFor();
}
-
+
@Test
public void testAjaxRendered() {
super.testAjaxRendered();
}
-
+
@Test
public void testRendered() {
super.testRendered();
}
-
+
@Test
- public void testShowSummary(){
- super.testShowSummary();
+ public void testShowSummary() {
+ super.testShowSummary();
}
-
+
@Test
- public void testShowDetail(){
+ public void testShowDetail() {
super.testShowDetail();
}
-
+
@Test
- public void testTitle(){
+ public void testTitle() {
super.testTitle();
}
-
+
@Test
- public void testDir(){
+ public void testDir() {
super.testDir();
}
-
+
@Test
- public void testLang(){
+ public void testLang() {
super.testLang();
}
-
+
@Test
- public void testStyle(){
+ public void testStyle() {
super.testStyle();
}
-
+
@Test
- public void testStyleClass(){
+ public void testStyleClass() {
super.testStyleClass();
}
-
+
@Test
public void testOnClick() {
super.testOnClick();
}
-
+
@Test
public void testOnDblClick() {
super.testOnDblClick();
}
-
+
@Test
public void testOnKeyDown() {
super.testOnKeyDown();
}
-
+
@Test
public void testOnKeyPress() {
super.testOnKeyPress();
}
-
+
@Test
public void testOnKeyUp() {
super.testOnKeyUp();
}
-
+
@Test
public void testOnMouseDown() {
super.testOnMouseDown();
}
-
+
@Test
public void testOnMouseMove() {
super.testOnMouseMove();
}
-
+
@Test
public void testOnMouseOut() {
super.testOnMouseOut();
}
-
+
@Test
public void testOnMouseOver() {
super.testOnMouseOver();
}
-
+
@Test
public void testOnMouseUp() {
super.testOnMouseUp();
Modified:
modules/tests/metamer/trunk/ftest-source/src/main/java/org/richfaces/tests/metamer/ftest/richMessage/TestRichMessageJSFValidator.java
===================================================================
---
modules/tests/metamer/trunk/ftest-source/src/main/java/org/richfaces/tests/metamer/ftest/richMessage/TestRichMessageJSFValidator.java 2011-05-06
18:23:48 UTC (rev 22478)
+++
modules/tests/metamer/trunk/ftest-source/src/main/java/org/richfaces/tests/metamer/ftest/richMessage/TestRichMessageJSFValidator.java 2011-05-06
18:27:42 UTC (rev 22479)
@@ -43,7 +43,7 @@
public URL getTestUrl() {
return buildUrl(contextPath,
"faces/components/richMessage/jsfValidator.xhtml");
}
-
+
@Override
public JQueryLocator getTestElemLocator() {
return mainMessage;
@@ -58,107 +58,105 @@
public JQueryLocator getDetailElemLocator() {
return detail;
}
-
+
// list of called test methods
-
@Test
- public void testFor(){
+ public void testFor() {
super.testFor();
}
-
+
@Test
public void testAjaxRendered() {
super.testAjaxRendered();
}
-
+
@Test
public void testRendered() {
super.testRendered();
}
-
+
@Test
- public void testShowSummary(){
- super.testShowSummary();
+ public void testShowSummary() {
+ super.testShowSummary();
}
-
+
@Test
- public void testShowDetail(){
+ public void testShowDetail() {
super.testShowDetail();
}
-
+
@Test
- public void testTitle(){
+ public void testTitle() {
super.testTitle();
}
-
+
@Test
- public void testDir(){
+ public void testDir() {
super.testDir();
}
-
+
@Test
- public void testLang(){
+ public void testLang() {
super.testLang();
}
-
+
@Test
- public void testStyle(){
+ public void testStyle() {
super.testStyle();
}
-
+
@Test
- public void testStyleClass(){
+ public void testStyleClass() {
super.testStyleClass();
}
-
+
@Test
public void testOnClick() {
super.testOnClick();
}
-
+
@Test
public void testOnDblClick() {
super.testOnDblClick();
}
-
+
@Test
public void testOnKeyDown() {
super.testOnKeyDown();
}
-
+
@Test
public void testOnKeyPress() {
super.testOnKeyPress();
}
-
+
@Test
public void testOnKeyUp() {
super.testOnKeyUp();
}
-
+
@Test
public void testOnMouseDown() {
super.testOnMouseDown();
}
-
+
@Test
public void testOnMouseMove() {
super.testOnMouseMove();
}
-
+
@Test
public void testOnMouseOut() {
super.testOnMouseOut();
}
-
+
@Test
public void testOnMouseOver() {
super.testOnMouseOver();
}
-
+
@Test
public void testOnMouseUp() {
super.testOnMouseUp();
}
-
}
Modified:
modules/tests/metamer/trunk/ftest-source/src/main/java/org/richfaces/tests/metamer/ftest/richMessage/TestRichMessageJSR303.java
===================================================================
---
modules/tests/metamer/trunk/ftest-source/src/main/java/org/richfaces/tests/metamer/ftest/richMessage/TestRichMessageJSR303.java 2011-05-06
18:23:48 UTC (rev 22478)
+++
modules/tests/metamer/trunk/ftest-source/src/main/java/org/richfaces/tests/metamer/ftest/richMessage/TestRichMessageJSR303.java 2011-05-06
18:27:42 UTC (rev 22479)
@@ -58,107 +58,105 @@
public JQueryLocator getDetailElemLocator() {
return detail;
}
-
+
// list of called test methods
-
@Test
- public void testFor(){
+ public void testFor() {
super.testFor();
}
-
+
@Test
public void testAjaxRendered() {
super.testAjaxRendered();
}
-
+
@Test
public void testRendered() {
super.testRendered();
}
-
+
@Test
- public void testShowSummary(){
- super.testShowSummary();
+ public void testShowSummary() {
+ super.testShowSummary();
}
-
+
@Test
- public void testShowDetail(){
+ public void testShowDetail() {
super.testShowDetail();
}
-
+
@Test
- public void testTitle(){
+ public void testTitle() {
super.testTitle();
}
-
+
@Test
- public void testDir(){
+ public void testDir() {
super.testDir();
}
-
+
@Test
- public void testLang(){
+ public void testLang() {
super.testLang();
}
-
+
@Test
- public void testStyle(){
+ public void testStyle() {
super.testStyle();
}
-
+
@Test
- public void testStyleClass(){
+ public void testStyleClass() {
super.testStyleClass();
}
-
+
@Test
public void testOnClick() {
super.testOnClick();
}
-
+
@Test
public void testOnDblClick() {
super.testOnDblClick();
}
-
+
@Test
public void testOnKeyDown() {
super.testOnKeyDown();
}
-
+
@Test
public void testOnKeyPress() {
super.testOnKeyPress();
}
-
+
@Test
public void testOnKeyUp() {
super.testOnKeyUp();
}
-
+
@Test
public void testOnMouseDown() {
super.testOnMouseDown();
}
-
+
@Test
public void testOnMouseMove() {
super.testOnMouseMove();
}
-
+
@Test
public void testOnMouseOut() {
super.testOnMouseOut();
}
-
+
@Test
public void testOnMouseOver() {
super.testOnMouseOver();
}
-
+
@Test
public void testOnMouseUp() {
super.testOnMouseUp();
}
-
}
Modified:
modules/tests/metamer/trunk/ftest-source/src/main/java/org/richfaces/tests/metamer/ftest/richMessages/RichMessagesTest.java
===================================================================
---
modules/tests/metamer/trunk/ftest-source/src/main/java/org/richfaces/tests/metamer/ftest/richMessages/RichMessagesTest.java 2011-05-06
18:23:48 UTC (rev 22478)
+++
modules/tests/metamer/trunk/ftest-source/src/main/java/org/richfaces/tests/metamer/ftest/richMessages/RichMessagesTest.java 2011-05-06
18:27:42 UTC (rev 22479)
@@ -25,9 +25,7 @@
import org.jboss.test.selenium.locator.JQueryLocator;
import org.richfaces.tests.metamer.ftest.richMessage.AbstractRichMessageTest;
-import org.testng.annotations.Test;
-
/**
* Abstract class with list of tests appropriate for rich:messages component
*
@@ -35,48 +33,49 @@
* @version $Revision$
*/
public abstract class RichMessagesTest extends AbstractRichMessageTest {
-
+
// locator for main rich:message component (tested element)
protected static JQueryLocator mainMsg1 = pjq("span[id$=msgs1]");
protected static JQueryLocator mainMsg2 = pjq("span[id$=msgs2]");
-
- // locators for
+ // locators for summary and detail in container
protected JQueryLocator summary =
getTestElemLocator().getDescendant(jq("span.rf-msgs-sum"));
protected JQueryLocator detail =
getTestElemLocator().getDescendant(jq("span.rf-msgs-det"));
-
protected JQueryLocator generateMsgsBtn =
pjq("input[id$=generateMsgsBtn]");
-
+
// Methods for error and warning message locators
private JQueryLocator getErrorMsg(JQueryLocator testElem) {
return testElem.getDescendant(jq("span.rf-msgs-err"));
- }
+ }
+
private JQueryLocator getWarnMsg(JQueryLocator testElem) {
- return testElem.getDescendant(jq("span.rf-msgs-wrn"));
- }
+ return testElem.getDescendant(jq("span.rf-msgs-wrn"));
+ }
+
private JQueryLocator getErrorMsg() {
return getErrorMsg(getTestElemLocator());
- }
+ }
+
private JQueryLocator getWarnMsg() {
return getWarnMsg(getTestElemLocator());
}
-
+
/**
* Attribute 'for' change behavior: only messages bound to element with
* id specified in 'for' should be displayed
*/
public void testFor() {
-
+
// firstly reset to null
attributes.setFor("");
-
+
// generate faces message by btn
selenium.click(generateMsgsBtn);
-
+
// no messages for simpleInput1 or simpleInput2 should appear
waitGui.until(countEquals.count(0).locator(getTestElemLocator().getChild(jq("span[id$=msgs1:form:simpleInput1]"))));
waitGui.until(countEquals.count(0).locator(getTestElemLocator().getChild(jq("span[id$=msgs1:form:simpleInput2]"))));
-
- attributes.setFor("simpleInput1");
+
+ attributes.setFor("simpleInput1");
// generate faces messages by btn
selenium.click(generateMsgsBtn);
// only messages for simpleInput1 should appear:
@@ -85,17 +84,17 @@
waitModel.until(countEquals.count(1).locator(getErrorMsg()));
// one type warning
waitModel.until(countEquals.count(1).locator(getWarnMsg()));
-
- attributes.setFor("simpleInput2");
+
+ attributes.setFor("simpleInput2");
// generate faces messages by btn
- selenium.click(generateMsgsBtn);
+ selenium.click(generateMsgsBtn);
// only 2 messages for simpleInput2
waitModel.until(countEquals.count(2).locator(getTestElemLocator().getChild(jq("span[id$=msgs1:form:simpleInput2]"))));
// only 2 messages should appear
waitModel.until(countEquals.count(1).locator(getErrorMsg()));
waitModel.until(countEquals.count(1).locator(getWarnMsg()));
}
-
+
/**
* globalOnly change behavior of displaying messages.
* When <b>true</b> only messages not bound to any input are displayed
@@ -109,12 +108,12 @@
public void testGlobalOnly() {
// firstly set for attribute to null
attributes.setFor("");
-
+
// then set globalOnly attribute
attributes.setGlobalOnly(Boolean.FALSE);
-
+
selenium.click(generateMsgsBtn);
-
+
// All messages should appear:
// for simpleInput1
waitModel.until(countEquals.count(2).locator(mainMsg2.getChild(jq("span[id$=:msgs2:form:simpleInput1]"))));
Modified:
modules/tests/metamer/trunk/ftest-source/src/main/java/org/richfaces/tests/metamer/ftest/richMessages/TestRichMessagesCSV.java
===================================================================
---
modules/tests/metamer/trunk/ftest-source/src/main/java/org/richfaces/tests/metamer/ftest/richMessages/TestRichMessagesCSV.java 2011-05-06
18:23:48 UTC (rev 22478)
+++
modules/tests/metamer/trunk/ftest-source/src/main/java/org/richfaces/tests/metamer/ftest/richMessages/TestRichMessagesCSV.java 2011-05-06
18:27:42 UTC (rev 22479)
@@ -35,7 +35,7 @@
* @version $Revision$
*/
public class TestRichMessagesCSV extends RichMessagesTest {
-
+
@Override
public URL getTestUrl() {
return buildUrl(contextPath,
"faces/components/richMessages/csv.xhtml");
@@ -55,112 +55,110 @@
public JQueryLocator getDetailElemLocator() {
return detail;
}
-
+
// list of called test methods
-
@Test
- public void testFor(){
+ public void testFor() {
super.testFor();
}
-
+
@Test
- public void testGlobalOnly(){
+ public void testGlobalOnly() {
super.testGlobalOnly();
}
-
+
@Test
public void testAjaxRendered() {
super.testAjaxRendered();
}
-
+
@Test
public void testRendered() {
super.testRendered();
}
-
+
@Test
- public void testShowSummary(){
- super.testShowSummary();
+ public void testShowSummary() {
+ super.testShowSummary();
}
-
+
@Test
- public void testShowDetail(){
+ public void testShowDetail() {
super.testShowDetail();
}
-
+
@Test
- public void testTitle(){
+ public void testTitle() {
super.testTitle();
}
-
+
@Test
- public void testDir(){
+ public void testDir() {
super.testDir();
}
-
+
@Test
- public void testLang(){
+ public void testLang() {
super.testLang();
}
-
+
@Test
- public void testStyle(){
+ public void testStyle() {
super.testStyle();
}
-
+
@Test
- public void testStyleClass(){
+ public void testStyleClass() {
super.testStyleClass();
}
-
+
@Test
public void testOnClick() {
super.testOnClick();
}
-
+
@Test
public void testOnDblClick() {
super.testOnDblClick();
}
-
+
@Test
public void testOnKeyDown() {
super.testOnKeyDown();
}
-
+
@Test
public void testOnKeyPress() {
super.testOnKeyPress();
}
-
+
@Test
public void testOnKeyUp() {
super.testOnKeyUp();
}
-
+
@Test
public void testOnMouseDown() {
super.testOnMouseDown();
}
-
+
@Test
public void testOnMouseMove() {
super.testOnMouseMove();
}
-
+
@Test
public void testOnMouseOut() {
super.testOnMouseOut();
}
-
+
@Test
public void testOnMouseOver() {
super.testOnMouseOver();
}
-
+
@Test
public void testOnMouseUp() {
super.testOnMouseUp();
}
-
}
Modified:
modules/tests/metamer/trunk/ftest-source/src/main/java/org/richfaces/tests/metamer/ftest/richMessages/TestRichMessagesJSFValidator.java
===================================================================
---
modules/tests/metamer/trunk/ftest-source/src/main/java/org/richfaces/tests/metamer/ftest/richMessages/TestRichMessagesJSFValidator.java 2011-05-06
18:23:48 UTC (rev 22478)
+++
modules/tests/metamer/trunk/ftest-source/src/main/java/org/richfaces/tests/metamer/ftest/richMessages/TestRichMessagesJSFValidator.java 2011-05-06
18:27:42 UTC (rev 22479)
@@ -35,7 +35,7 @@
* @version $Revision$
*/
public class TestRichMessagesJSFValidator extends RichMessagesTest {
-
+
@Override
public URL getTestUrl() {
return buildUrl(contextPath,
"faces/components/richMessages/jsfValidator.xhtml");
@@ -55,112 +55,110 @@
public JQueryLocator getDetailElemLocator() {
return detail;
}
-
+
// list of called test methods
-
@Test
- public void testFor(){
+ public void testFor() {
super.testFor();
}
-
+
@Test
- public void testGlobalOnly(){
+ public void testGlobalOnly() {
super.testGlobalOnly();
}
-
+
@Test
public void testAjaxRendered() {
super.testAjaxRendered();
}
-
+
@Test
public void testRendered() {
super.testRendered();
}
-
+
@Test
- public void testShowSummary(){
- super.testShowSummary();
+ public void testShowSummary() {
+ super.testShowSummary();
}
-
+
@Test
- public void testShowDetail(){
+ public void testShowDetail() {
super.testShowDetail();
}
-
+
@Test
- public void testTitle(){
+ public void testTitle() {
super.testTitle();
}
-
+
@Test
- public void testDir(){
+ public void testDir() {
super.testDir();
}
-
+
@Test
- public void testLang(){
+ public void testLang() {
super.testLang();
}
-
+
@Test
- public void testStyle(){
+ public void testStyle() {
super.testStyle();
}
-
+
@Test
- public void testStyleClass(){
+ public void testStyleClass() {
super.testStyleClass();
}
-
+
@Test
public void testOnClick() {
super.testOnClick();
}
-
+
@Test
public void testOnDblClick() {
super.testOnDblClick();
}
-
+
@Test
public void testOnKeyDown() {
super.testOnKeyDown();
}
-
+
@Test
public void testOnKeyPress() {
super.testOnKeyPress();
}
-
+
@Test
public void testOnKeyUp() {
super.testOnKeyUp();
}
-
+
@Test
public void testOnMouseDown() {
super.testOnMouseDown();
}
-
+
@Test
public void testOnMouseMove() {
super.testOnMouseMove();
}
-
+
@Test
public void testOnMouseOut() {
super.testOnMouseOut();
}
-
+
@Test
public void testOnMouseOver() {
super.testOnMouseOver();
}
-
+
@Test
public void testOnMouseUp() {
super.testOnMouseUp();
}
-
}
Modified:
modules/tests/metamer/trunk/ftest-source/src/main/java/org/richfaces/tests/metamer/ftest/richMessages/TestRichMessagesJSR303.java
===================================================================
---
modules/tests/metamer/trunk/ftest-source/src/main/java/org/richfaces/tests/metamer/ftest/richMessages/TestRichMessagesJSR303.java 2011-05-06
18:23:48 UTC (rev 22478)
+++
modules/tests/metamer/trunk/ftest-source/src/main/java/org/richfaces/tests/metamer/ftest/richMessages/TestRichMessagesJSR303.java 2011-05-06
18:27:42 UTC (rev 22479)
@@ -35,7 +35,7 @@
* @version $Revision$
*/
public class TestRichMessagesJSR303 extends RichMessagesTest {
-
+
@Override
public URL getTestUrl() {
return buildUrl(contextPath,
"faces/components/richMessages/jsr303.xhtml");
@@ -55,112 +55,110 @@
public JQueryLocator getDetailElemLocator() {
return detail;
}
-
+
// list of called test methods
-
@Test
- public void testFor(){
+ public void testFor() {
super.testFor();
}
-
+
@Test
- public void testGlobalOnly(){
+ public void testGlobalOnly() {
super.testGlobalOnly();
}
-
+
@Test
public void testAjaxRendered() {
super.testAjaxRendered();
}
-
+
@Test
public void testRendered() {
super.testRendered();
}
-
+
@Test
- public void testShowSummary(){
- super.testShowSummary();
+ public void testShowSummary() {
+ super.testShowSummary();
}
-
+
@Test
- public void testShowDetail(){
+ public void testShowDetail() {
super.testShowDetail();
}
-
+
@Test
- public void testTitle(){
+ public void testTitle() {
super.testTitle();
}
-
+
@Test
- public void testDir(){
+ public void testDir() {
super.testDir();
}
-
+
@Test
- public void testLang(){
+ public void testLang() {
super.testLang();
}
-
+
@Test
- public void testStyle(){
+ public void testStyle() {
super.testStyle();
}
-
+
@Test
- public void testStyleClass(){
+ public void testStyleClass() {
super.testStyleClass();
}
-
+
@Test
public void testOnClick() {
super.testOnClick();
}
-
+
@Test
public void testOnDblClick() {
super.testOnDblClick();
}
-
+
@Test
public void testOnKeyDown() {
super.testOnKeyDown();
}
-
+
@Test
public void testOnKeyPress() {
super.testOnKeyPress();
}
-
+
@Test
public void testOnKeyUp() {
super.testOnKeyUp();
}
-
+
@Test
public void testOnMouseDown() {
super.testOnMouseDown();
}
-
+
@Test
public void testOnMouseMove() {
super.testOnMouseMove();
}
-
+
@Test
public void testOnMouseOut() {
super.testOnMouseOut();
}
-
+
@Test
public void testOnMouseOver() {
super.testOnMouseOver();
}
-
+
@Test
public void testOnMouseUp() {
super.testOnMouseUp();
}
-
}