You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@myfaces.apache.org by ja...@apache.org on 2010/07/28 11:43:18 UTC
svn commit: r980006 - in /myfaces/core/trunk/impl/src/test:
java/org/apache/myfaces/view/facelets/tag/ui/
resources/org/apache/myfaces/view/facelets/tag/ui/
Author: jakobk
Date: Wed Jul 28 09:43:17 2010
New Revision: 980006
URL: http://svn.apache.org/viewvc?rev=980006&view=rev
Log:
MYFACES-2753 Trivial multi-level templating does not work if ui:include is used (additional test cases)
Added:
myfaces/core/trunk/impl/src/test/resources/org/apache/myfaces/view/facelets/tag/ui/composition_with_template.xhtml (with props)
myfaces/core/trunk/impl/src/test/resources/org/apache/myfaces/view/facelets/tag/ui/composition_with_template_and_define.xhtml (with props)
myfaces/core/trunk/impl/src/test/resources/org/apache/myfaces/view/facelets/tag/ui/decorate_with_template.xhtml (with props)
myfaces/core/trunk/impl/src/test/resources/org/apache/myfaces/view/facelets/tag/ui/decorate_with_template_and_define.xhtml (with props)
myfaces/core/trunk/impl/src/test/resources/org/apache/myfaces/view/facelets/tag/ui/multilevel_template_InnerClient.xhtml (with props)
myfaces/core/trunk/impl/src/test/resources/org/apache/myfaces/view/facelets/tag/ui/multilevel_template_InnerClient_with_define.xhtml (with props)
myfaces/core/trunk/impl/src/test/resources/org/apache/myfaces/view/facelets/tag/ui/multilevel_template_InnerTemplate.xhtml (with props)
myfaces/core/trunk/impl/src/test/resources/org/apache/myfaces/view/facelets/tag/ui/multilevel_template_OuterClient.xhtml (with props)
myfaces/core/trunk/impl/src/test/resources/org/apache/myfaces/view/facelets/tag/ui/multilevel_template_OuterClient_with_define.xhtml (with props)
myfaces/core/trunk/impl/src/test/resources/org/apache/myfaces/view/facelets/tag/ui/multilevel_template_OuterTemplate.xhtml (with props)
myfaces/core/trunk/impl/src/test/resources/org/apache/myfaces/view/facelets/tag/ui/s_page_composition.xhtml
- copied unchanged from r979764, myfaces/core/trunk/impl/src/test/resources/org/apache/myfaces/view/facelets/tag/ui/s_page.xhtml
myfaces/core/trunk/impl/src/test/resources/org/apache/myfaces/view/facelets/tag/ui/s_page_decorate.xhtml (with props)
myfaces/core/trunk/impl/src/test/resources/org/apache/myfaces/view/facelets/tag/ui/template_with_insert.xhtml (with props)
Removed:
myfaces/core/trunk/impl/src/test/resources/org/apache/myfaces/view/facelets/tag/ui/s_page.xhtml
Modified:
myfaces/core/trunk/impl/src/test/java/org/apache/myfaces/view/facelets/tag/ui/TemplateTestCase.java
myfaces/core/trunk/impl/src/test/resources/org/apache/myfaces/view/facelets/tag/ui/s_layout.xhtml
Modified: myfaces/core/trunk/impl/src/test/java/org/apache/myfaces/view/facelets/tag/ui/TemplateTestCase.java
URL: http://svn.apache.org/viewvc/myfaces/core/trunk/impl/src/test/java/org/apache/myfaces/view/facelets/tag/ui/TemplateTestCase.java?rev=980006&r1=980005&r2=980006&view=diff
==============================================================================
--- myfaces/core/trunk/impl/src/test/java/org/apache/myfaces/view/facelets/tag/ui/TemplateTestCase.java (original)
+++ myfaces/core/trunk/impl/src/test/java/org/apache/myfaces/view/facelets/tag/ui/TemplateTestCase.java Wed Jul 28 09:43:17 2010
@@ -16,7 +16,6 @@
* specific language governing permissions and limitations
* under the License.
*/
-
package org.apache.myfaces.view.facelets.tag.ui;
import javax.faces.component.UIViewRoot;
@@ -27,41 +26,191 @@ import org.apache.myfaces.view.facelets.
import org.junit.Assert;
import org.junit.Test;
-public class TemplateTestCase extends FaceletTestCase {
+/**
+ * Test cases related to the Faceletes templating mechanism.
+ *
+ * @author Jakob Korherr (latest modification by $Author$)
+ * @version $Revision$ $Date$
+ */
+public class TemplateTestCase extends FaceletTestCase
+{
+
+ private FastWriter _writer;
- @Override
- protected void setupComponents() throws Exception
+ public void setUp() throws Exception
{
- application.addComponent(UIViewRoot.COMPONENT_TYPE,
- UIViewRoot.class.getName());
+ super.setUp();
+
+ // install the FastWriter
+ _writer = new FastWriter();
+ ResponseWriter rw = facesContext.getResponseWriter();
+ rw = rw.cloneWithWriter(_writer);
+ facesContext.setResponseWriter(rw);
}
@Override
- protected void setupConvertersAndValidators() throws Exception
+ public void tearDown() throws Exception
{
+ _writer = null;
+
+ super.tearDown();
}
- @Override
- protected void setupRenderers() throws Exception
+ /**
+ * Tests the case when <ui:insert> is used without a name attribute.
+ * In this case the body of the surrounding <ui:composition> must be inserted.
+ * @throws Exception
+ */
+ @Test
+ public void testInsertWithoutNameComposition() throws Exception
{
+ _testInsertWithoutName("s_page_composition.xhtml");
}
+ /**
+ * Tests the case when <ui:insert> is used without a name attribute.
+ * In this case the body of the surrounding <ui:decorate> must be inserted.
+ * @throws Exception
+ */
@Test
- public void testOutput() throws Exception {
+ public void testInsertWithoutNameDecorate() throws Exception
+ {
+ _testInsertWithoutName("s_page_decorate.xhtml");
+ }
+
+ private void _testInsertWithoutName(String page) throws Exception
+ {
UIViewRoot root = facesContext.getViewRoot();
- vdl.buildView(facesContext, root, "s_page.xhtml");
-
- FastWriter fw = new FastWriter();
- ResponseWriter rw = facesContext.getResponseWriter();
- rw = rw.cloneWithWriter(fw);
- facesContext.setResponseWriter(rw);
+ vdl.buildView(facesContext, root, page);
+
+ // render view
+ root.encodeAll(facesContext);
+ final String output = _writer.toString();
+
+ // assertions
+ Assert.assertTrue(output.contains("<span id=\"body\">BODY</span>"));
+ Assert.assertTrue(output.contains("<span id=\"popupSpan\"><p>[POPUPCONTENT]</p></span>"));
+ }
+
+ /**
+ * Tests the case when there's a <ui:decorate> with a template that inserts
+ * a property defined by the <ui:decorate>.
+ * @throws Exception
+ */
+ @Test
+ public void testInsertWithDefinedNameDecorate() throws Exception
+ {
+ _testInsertWithDefinedName("decorate_with_template_and_define.xhtml");
+ }
+
+ /**
+ * Tests the case when there's a <ui:composition> with a template that inserts
+ * a property defined by the <ui:composition>.
+ * @throws Exception
+ */
+ @Test
+ public void testInsertWithDefinedNameComposition() throws Exception
+ {
+ _testInsertWithDefinedName("composition_with_template_and_define.xhtml");
+ }
+
+ private void _testInsertWithDefinedName(String page) throws Exception
+ {
+ UIViewRoot root = facesContext.getViewRoot();
+ vdl.buildView(facesContext, root, page);
+
+ // render view
+ root.encodeAll(facesContext);
+ final String output = _writer.toString();
+
+ // assertions
+ Assert.assertTrue(output.contains("<span>defined content</span>"));
+ }
+
+ /**
+ * Tests the case when there's a <ui:decorate> with a template that wants to
+ * insert a property defined by the <ui:decorate>, but the property was not
+ * defined. In this case the default value (= body of <ui:insert>) must be rendered.
+ * @throws Exception
+ */
+ @Test
+ public void testInsertWithoutDefinedNameDecorate() throws Exception
+ {
+ _testInsertWithoutDefinedName("decorate_with_template.xhtml");
+ }
+
+ /**
+ * Tests the case when there's a <ui:composition> with a template that wants to
+ * insert a property defined by the <ui:composition>, but the property was not
+ * defined. In this case the default value (= body of <ui:insert>) must be rendered.
+ * @throws Exception
+ */
+ @Test
+ public void testInsertWithoutDefinedNameComposition() throws Exception
+ {
+ _testInsertWithoutDefinedName("composition_with_template.xhtml");
+ }
+
+ private void _testInsertWithoutDefinedName(String page) throws Exception
+ {
+ UIViewRoot root = facesContext.getViewRoot();
+ vdl.buildView(facesContext, root, page);
+
+ // render view
+ root.encodeAll(facesContext);
+ final String output = _writer.toString();
+
+ // assertions
+ Assert.assertTrue(output
+ .contains("<span>default ui:insert content</span>"));
+ }
+
+ /**
+ * Tests multilevel templating. In this case multilevel_template_OuterClient_with_define.xhtml
+ * is a <ui:decorate> which has a template and a defined content of a <ui:include> of
+ * multilevel_template_InnerClient_with_define.xhtml, which itself has a template and a defined
+ * content of "inner content".
+ * @throws Exception
+ */
+ @Test
+ public void _testMultilevelTemplating() throws Exception
+ {
+ UIViewRoot root = facesContext.getViewRoot();
+ vdl.buildView(facesContext, root,
+ "multilevel_template_OuterClient_with_define.xhtml");
+
+ // render view
+ root.encodeAll(facesContext);
+ String output = _writer.toString();
+ output = output.replaceAll("(?s)<!--.*?-->", ""); // remove license headers for clarity
+
+ // assertions
+ Assert.assertTrue(output.contains("<body>inner content</body>"));
+ }
+
+ /**
+ * Tests multilevel templating. In this case multilevel_template_OuterClient_with_define.xhtml
+ * is a <ui:decorate> which has a template and a defined content of a <ui:include> of
+ * multilevel_template_InnerClient_with_define.xhtml, which itself has a template, but not a
+ * defined content. However it inserts content and thus it must use the fallback content of
+ * the innerTemplate.
+ * @throws Exception
+ */
+ @Test
+ public void _testMultilevelTemplatingInnerFallback() throws Exception
+ {
+ UIViewRoot root = facesContext.getViewRoot();
+ vdl.buildView(facesContext, root,
+ "multilevel_template_OuterClient.xhtml");
+
+ // render view
root.encodeAll(facesContext);
- //System.out.println(fw);
-
- String response = fw.toString();
+ String output = _writer.toString();
+ output = output.replaceAll("(?s)<!--.*?-->", ""); // remove license headers for clarity
- Assert.assertTrue(response.contains("<span id=\"popupSpan\"><p>[POPUPCONTENT]</p></span>"));
- Assert.assertTrue(response.contains("<span id=\"body\">BODY</span>"));
+ // assertions
+ Assert.assertTrue(output
+ .contains("<body>inner fallback content</body>"));
}
}
Added: myfaces/core/trunk/impl/src/test/resources/org/apache/myfaces/view/facelets/tag/ui/composition_with_template.xhtml
URL: http://svn.apache.org/viewvc/myfaces/core/trunk/impl/src/test/resources/org/apache/myfaces/view/facelets/tag/ui/composition_with_template.xhtml?rev=980006&view=auto
==============================================================================
--- myfaces/core/trunk/impl/src/test/resources/org/apache/myfaces/view/facelets/tag/ui/composition_with_template.xhtml (added)
+++ myfaces/core/trunk/impl/src/test/resources/org/apache/myfaces/view/facelets/tag/ui/composition_with_template.xhtml Wed Jul 28 09:43:17 2010
@@ -0,0 +1,21 @@
+<!--
+ Licensed to the Apache Software Foundation (ASF) under one or more
+ contributor license agreements. See the NOTICE file distributed with
+ this work for additional information regarding copyright ownership.
+ The ASF licenses this file to You under the Apache License, Version 2.0
+ (the "License"); you may not use this file except in compliance with
+ the License. You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+-->
+<ui:composition
+ template="/template_with_insert.xhtml"
+ xmlns:ui="http://java.sun.com/jsf/facelets">
+
+</ui:composition>
Propchange: myfaces/core/trunk/impl/src/test/resources/org/apache/myfaces/view/facelets/tag/ui/composition_with_template.xhtml
------------------------------------------------------------------------------
svn:eol-style = native
Propchange: myfaces/core/trunk/impl/src/test/resources/org/apache/myfaces/view/facelets/tag/ui/composition_with_template.xhtml
------------------------------------------------------------------------------
svn:mime-type = text/plain
Added: myfaces/core/trunk/impl/src/test/resources/org/apache/myfaces/view/facelets/tag/ui/composition_with_template_and_define.xhtml
URL: http://svn.apache.org/viewvc/myfaces/core/trunk/impl/src/test/resources/org/apache/myfaces/view/facelets/tag/ui/composition_with_template_and_define.xhtml?rev=980006&view=auto
==============================================================================
--- myfaces/core/trunk/impl/src/test/resources/org/apache/myfaces/view/facelets/tag/ui/composition_with_template_and_define.xhtml (added)
+++ myfaces/core/trunk/impl/src/test/resources/org/apache/myfaces/view/facelets/tag/ui/composition_with_template_and_define.xhtml Wed Jul 28 09:43:17 2010
@@ -0,0 +1,21 @@
+<!--
+ Licensed to the Apache Software Foundation (ASF) under one or more
+ contributor license agreements. See the NOTICE file distributed with
+ this work for additional information regarding copyright ownership.
+ The ASF licenses this file to You under the Apache License, Version 2.0
+ (the "License"); you may not use this file except in compliance with
+ the License. You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+-->
+<ui:composition
+ template="/template_with_insert.xhtml"
+ xmlns:ui="http://java.sun.com/jsf/facelets">
+ <ui:define name="content">defined content</ui:define>
+</ui:composition>
Propchange: myfaces/core/trunk/impl/src/test/resources/org/apache/myfaces/view/facelets/tag/ui/composition_with_template_and_define.xhtml
------------------------------------------------------------------------------
svn:eol-style = native
Propchange: myfaces/core/trunk/impl/src/test/resources/org/apache/myfaces/view/facelets/tag/ui/composition_with_template_and_define.xhtml
------------------------------------------------------------------------------
svn:mime-type = text/plain
Added: myfaces/core/trunk/impl/src/test/resources/org/apache/myfaces/view/facelets/tag/ui/decorate_with_template.xhtml
URL: http://svn.apache.org/viewvc/myfaces/core/trunk/impl/src/test/resources/org/apache/myfaces/view/facelets/tag/ui/decorate_with_template.xhtml?rev=980006&view=auto
==============================================================================
--- myfaces/core/trunk/impl/src/test/resources/org/apache/myfaces/view/facelets/tag/ui/decorate_with_template.xhtml (added)
+++ myfaces/core/trunk/impl/src/test/resources/org/apache/myfaces/view/facelets/tag/ui/decorate_with_template.xhtml Wed Jul 28 09:43:17 2010
@@ -0,0 +1,21 @@
+<!--
+ Licensed to the Apache Software Foundation (ASF) under one or more
+ contributor license agreements. See the NOTICE file distributed with
+ this work for additional information regarding copyright ownership.
+ The ASF licenses this file to You under the Apache License, Version 2.0
+ (the "License"); you may not use this file except in compliance with
+ the License. You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+-->
+<ui:decorate
+ template="/template_with_insert.xhtml"
+ xmlns:ui="http://java.sun.com/jsf/facelets">
+
+</ui:decorate>
Propchange: myfaces/core/trunk/impl/src/test/resources/org/apache/myfaces/view/facelets/tag/ui/decorate_with_template.xhtml
------------------------------------------------------------------------------
svn:eol-style = native
Propchange: myfaces/core/trunk/impl/src/test/resources/org/apache/myfaces/view/facelets/tag/ui/decorate_with_template.xhtml
------------------------------------------------------------------------------
svn:mime-type = text/plain
Added: myfaces/core/trunk/impl/src/test/resources/org/apache/myfaces/view/facelets/tag/ui/decorate_with_template_and_define.xhtml
URL: http://svn.apache.org/viewvc/myfaces/core/trunk/impl/src/test/resources/org/apache/myfaces/view/facelets/tag/ui/decorate_with_template_and_define.xhtml?rev=980006&view=auto
==============================================================================
--- myfaces/core/trunk/impl/src/test/resources/org/apache/myfaces/view/facelets/tag/ui/decorate_with_template_and_define.xhtml (added)
+++ myfaces/core/trunk/impl/src/test/resources/org/apache/myfaces/view/facelets/tag/ui/decorate_with_template_and_define.xhtml Wed Jul 28 09:43:17 2010
@@ -0,0 +1,21 @@
+<!--
+ Licensed to the Apache Software Foundation (ASF) under one or more
+ contributor license agreements. See the NOTICE file distributed with
+ this work for additional information regarding copyright ownership.
+ The ASF licenses this file to You under the Apache License, Version 2.0
+ (the "License"); you may not use this file except in compliance with
+ the License. You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+-->
+<ui:decorate
+ template="/template_with_insert.xhtml"
+ xmlns:ui="http://java.sun.com/jsf/facelets">
+ <ui:define name="content">defined content</ui:define>
+</ui:decorate>
Propchange: myfaces/core/trunk/impl/src/test/resources/org/apache/myfaces/view/facelets/tag/ui/decorate_with_template_and_define.xhtml
------------------------------------------------------------------------------
svn:eol-style = native
Propchange: myfaces/core/trunk/impl/src/test/resources/org/apache/myfaces/view/facelets/tag/ui/decorate_with_template_and_define.xhtml
------------------------------------------------------------------------------
svn:mime-type = text/plain
Added: myfaces/core/trunk/impl/src/test/resources/org/apache/myfaces/view/facelets/tag/ui/multilevel_template_InnerClient.xhtml
URL: http://svn.apache.org/viewvc/myfaces/core/trunk/impl/src/test/resources/org/apache/myfaces/view/facelets/tag/ui/multilevel_template_InnerClient.xhtml?rev=980006&view=auto
==============================================================================
--- myfaces/core/trunk/impl/src/test/resources/org/apache/myfaces/view/facelets/tag/ui/multilevel_template_InnerClient.xhtml (added)
+++ myfaces/core/trunk/impl/src/test/resources/org/apache/myfaces/view/facelets/tag/ui/multilevel_template_InnerClient.xhtml Wed Jul 28 09:43:17 2010
@@ -0,0 +1,22 @@
+<!--
+ Licensed to the Apache Software Foundation (ASF) under one or more
+ contributor license agreements. See the NOTICE file distributed with
+ this work for additional information regarding copyright ownership.
+ The ASF licenses this file to You under the Apache License, Version 2.0
+ (the "License"); you may not use this file except in compliance with
+ the License. You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+-->
+<ui:composition
+ template="/multilevel_template_InnerTemplate.xhtml"
+ xmlns="http://www.w3.org/1999/xhtml"
+ xmlns:ui="http://java.sun.com/jsf/facelets">
+
+</ui:composition>
Propchange: myfaces/core/trunk/impl/src/test/resources/org/apache/myfaces/view/facelets/tag/ui/multilevel_template_InnerClient.xhtml
------------------------------------------------------------------------------
svn:eol-style = native
Propchange: myfaces/core/trunk/impl/src/test/resources/org/apache/myfaces/view/facelets/tag/ui/multilevel_template_InnerClient.xhtml
------------------------------------------------------------------------------
svn:mime-type = text/plain
Added: myfaces/core/trunk/impl/src/test/resources/org/apache/myfaces/view/facelets/tag/ui/multilevel_template_InnerClient_with_define.xhtml
URL: http://svn.apache.org/viewvc/myfaces/core/trunk/impl/src/test/resources/org/apache/myfaces/view/facelets/tag/ui/multilevel_template_InnerClient_with_define.xhtml?rev=980006&view=auto
==============================================================================
--- myfaces/core/trunk/impl/src/test/resources/org/apache/myfaces/view/facelets/tag/ui/multilevel_template_InnerClient_with_define.xhtml (added)
+++ myfaces/core/trunk/impl/src/test/resources/org/apache/myfaces/view/facelets/tag/ui/multilevel_template_InnerClient_with_define.xhtml Wed Jul 28 09:43:17 2010
@@ -0,0 +1,23 @@
+<!--
+ Licensed to the Apache Software Foundation (ASF) under one or more
+ contributor license agreements. See the NOTICE file distributed with
+ this work for additional information regarding copyright ownership.
+ The ASF licenses this file to You under the Apache License, Version 2.0
+ (the "License"); you may not use this file except in compliance with
+ the License. You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+-->
+<ui:composition
+ template="/multilevel_template_InnerTemplate.xhtml"
+ xmlns="http://www.w3.org/1999/xhtml"
+ xmlns:ui="http://java.sun.com/jsf/facelets">
+
+ <ui:define name="content">inner content</ui:define>
+</ui:composition>
Propchange: myfaces/core/trunk/impl/src/test/resources/org/apache/myfaces/view/facelets/tag/ui/multilevel_template_InnerClient_with_define.xhtml
------------------------------------------------------------------------------
svn:eol-style = native
Propchange: myfaces/core/trunk/impl/src/test/resources/org/apache/myfaces/view/facelets/tag/ui/multilevel_template_InnerClient_with_define.xhtml
------------------------------------------------------------------------------
svn:mime-type = text/plain
Added: myfaces/core/trunk/impl/src/test/resources/org/apache/myfaces/view/facelets/tag/ui/multilevel_template_InnerTemplate.xhtml
URL: http://svn.apache.org/viewvc/myfaces/core/trunk/impl/src/test/resources/org/apache/myfaces/view/facelets/tag/ui/multilevel_template_InnerTemplate.xhtml?rev=980006&view=auto
==============================================================================
--- myfaces/core/trunk/impl/src/test/resources/org/apache/myfaces/view/facelets/tag/ui/multilevel_template_InnerTemplate.xhtml (added)
+++ myfaces/core/trunk/impl/src/test/resources/org/apache/myfaces/view/facelets/tag/ui/multilevel_template_InnerTemplate.xhtml Wed Jul 28 09:43:17 2010
@@ -0,0 +1,23 @@
+<!--
+ Licensed to the Apache Software Foundation (ASF) under one or more
+ contributor license agreements. See the NOTICE file distributed with
+ this work for additional information regarding copyright ownership.
+ The ASF licenses this file to You under the Apache License, Version 2.0
+ (the "License"); you may not use this file except in compliance with
+ the License. You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+-->
+<f:subview
+ xmlns:ui="http://java.sun.com/jsf/facelets"
+ xmlns:f="http://java.sun.com/jsf/core">
+
+ <ui:insert name="content">inner fallback content</ui:insert>
+
+</f:subview>
Propchange: myfaces/core/trunk/impl/src/test/resources/org/apache/myfaces/view/facelets/tag/ui/multilevel_template_InnerTemplate.xhtml
------------------------------------------------------------------------------
svn:eol-style = native
Propchange: myfaces/core/trunk/impl/src/test/resources/org/apache/myfaces/view/facelets/tag/ui/multilevel_template_InnerTemplate.xhtml
------------------------------------------------------------------------------
svn:mime-type = text/plain
Added: myfaces/core/trunk/impl/src/test/resources/org/apache/myfaces/view/facelets/tag/ui/multilevel_template_OuterClient.xhtml
URL: http://svn.apache.org/viewvc/myfaces/core/trunk/impl/src/test/resources/org/apache/myfaces/view/facelets/tag/ui/multilevel_template_OuterClient.xhtml?rev=980006&view=auto
==============================================================================
--- myfaces/core/trunk/impl/src/test/resources/org/apache/myfaces/view/facelets/tag/ui/multilevel_template_OuterClient.xhtml (added)
+++ myfaces/core/trunk/impl/src/test/resources/org/apache/myfaces/view/facelets/tag/ui/multilevel_template_OuterClient.xhtml Wed Jul 28 09:43:17 2010
@@ -0,0 +1,24 @@
+<!--
+ Licensed to the Apache Software Foundation (ASF) under one or more
+ contributor license agreements. See the NOTICE file distributed with
+ this work for additional information regarding copyright ownership.
+ The ASF licenses this file to You under the Apache License, Version 2.0
+ (the "License"); you may not use this file except in compliance with
+ the License. You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+-->
+<ui:decorate
+ template="/multilevel_template_OuterTemplate.xhtml"
+ xmlns:ui="http://java.sun.com/jsf/facelets">
+
+ <ui:define name="content">
+ <ui:include src="multilevel_template_InnerClient.xhtml" />
+ </ui:define>
+</ui:decorate>
Propchange: myfaces/core/trunk/impl/src/test/resources/org/apache/myfaces/view/facelets/tag/ui/multilevel_template_OuterClient.xhtml
------------------------------------------------------------------------------
svn:eol-style = native
Propchange: myfaces/core/trunk/impl/src/test/resources/org/apache/myfaces/view/facelets/tag/ui/multilevel_template_OuterClient.xhtml
------------------------------------------------------------------------------
svn:mime-type = text/plain
Added: myfaces/core/trunk/impl/src/test/resources/org/apache/myfaces/view/facelets/tag/ui/multilevel_template_OuterClient_with_define.xhtml
URL: http://svn.apache.org/viewvc/myfaces/core/trunk/impl/src/test/resources/org/apache/myfaces/view/facelets/tag/ui/multilevel_template_OuterClient_with_define.xhtml?rev=980006&view=auto
==============================================================================
--- myfaces/core/trunk/impl/src/test/resources/org/apache/myfaces/view/facelets/tag/ui/multilevel_template_OuterClient_with_define.xhtml (added)
+++ myfaces/core/trunk/impl/src/test/resources/org/apache/myfaces/view/facelets/tag/ui/multilevel_template_OuterClient_with_define.xhtml Wed Jul 28 09:43:17 2010
@@ -0,0 +1,24 @@
+<!--
+ Licensed to the Apache Software Foundation (ASF) under one or more
+ contributor license agreements. See the NOTICE file distributed with
+ this work for additional information regarding copyright ownership.
+ The ASF licenses this file to You under the Apache License, Version 2.0
+ (the "License"); you may not use this file except in compliance with
+ the License. You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+-->
+<ui:decorate
+ template="/multilevel_template_OuterTemplate.xhtml"
+ xmlns:ui="http://java.sun.com/jsf/facelets">
+
+ <ui:define name="content">
+ <ui:include src="multilevel_template_InnerClient_with_define.xhtml" />
+ </ui:define>
+</ui:decorate>
Propchange: myfaces/core/trunk/impl/src/test/resources/org/apache/myfaces/view/facelets/tag/ui/multilevel_template_OuterClient_with_define.xhtml
------------------------------------------------------------------------------
svn:eol-style = native
Propchange: myfaces/core/trunk/impl/src/test/resources/org/apache/myfaces/view/facelets/tag/ui/multilevel_template_OuterClient_with_define.xhtml
------------------------------------------------------------------------------
svn:mime-type = text/plain
Added: myfaces/core/trunk/impl/src/test/resources/org/apache/myfaces/view/facelets/tag/ui/multilevel_template_OuterTemplate.xhtml
URL: http://svn.apache.org/viewvc/myfaces/core/trunk/impl/src/test/resources/org/apache/myfaces/view/facelets/tag/ui/multilevel_template_OuterTemplate.xhtml?rev=980006&view=auto
==============================================================================
--- myfaces/core/trunk/impl/src/test/resources/org/apache/myfaces/view/facelets/tag/ui/multilevel_template_OuterTemplate.xhtml (added)
+++ myfaces/core/trunk/impl/src/test/resources/org/apache/myfaces/view/facelets/tag/ui/multilevel_template_OuterTemplate.xhtml Wed Jul 28 09:43:17 2010
@@ -0,0 +1,33 @@
+<!--
+ Licensed to the Apache Software Foundation (ASF) under one or more
+ contributor license agreements. See the NOTICE file distributed with
+ this work for additional information regarding copyright ownership.
+ The ASF licenses this file to You under the Apache License, Version 2.0
+ (the "License"); you may not use this file except in compliance with
+ the License. You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+-->
+<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
+<html
+ xmlns="http://www.w3.org/1999/xhtml"
+ xmlns:ui="http://java.sun.com/jsf/facelets"
+ xmlns:f="http://java.sun.com/jsf/core"
+ xmlns:h="http://java.sun.com/jsf/html">
+<f:view>
+ <h:head>
+ <title>Multilevel templating test</title>
+ </h:head>
+
+ <h:body>
+ <ui:insert name="content">outer fallback content</ui:insert>
+ </h:body>
+
+</f:view>
+</html>
Propchange: myfaces/core/trunk/impl/src/test/resources/org/apache/myfaces/view/facelets/tag/ui/multilevel_template_OuterTemplate.xhtml
------------------------------------------------------------------------------
svn:eol-style = native
Propchange: myfaces/core/trunk/impl/src/test/resources/org/apache/myfaces/view/facelets/tag/ui/multilevel_template_OuterTemplate.xhtml
------------------------------------------------------------------------------
svn:mime-type = text/plain
Modified: myfaces/core/trunk/impl/src/test/resources/org/apache/myfaces/view/facelets/tag/ui/s_layout.xhtml
URL: http://svn.apache.org/viewvc/myfaces/core/trunk/impl/src/test/resources/org/apache/myfaces/view/facelets/tag/ui/s_layout.xhtml?rev=980006&r1=980005&r2=980006&view=diff
==============================================================================
--- myfaces/core/trunk/impl/src/test/resources/org/apache/myfaces/view/facelets/tag/ui/s_layout.xhtml (original)
+++ myfaces/core/trunk/impl/src/test/resources/org/apache/myfaces/view/facelets/tag/ui/s_layout.xhtml Wed Jul 28 09:43:17 2010
@@ -21,7 +21,7 @@
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1"/>
</head>
<body>
- <ui:decorate template="s_popup.xhtml">POPUPCONTENT</ui:decorate>
- <span id="body"><ui:insert/></span>
+ <span id="body"><ui:insert/></span>
+ <ui:decorate template="s_popup.xhtml">POPUPCONTENT</ui:decorate>
</body>
</html>
\ No newline at end of file
Added: myfaces/core/trunk/impl/src/test/resources/org/apache/myfaces/view/facelets/tag/ui/s_page_decorate.xhtml
URL: http://svn.apache.org/viewvc/myfaces/core/trunk/impl/src/test/resources/org/apache/myfaces/view/facelets/tag/ui/s_page_decorate.xhtml?rev=980006&view=auto
==============================================================================
--- myfaces/core/trunk/impl/src/test/resources/org/apache/myfaces/view/facelets/tag/ui/s_page_decorate.xhtml (added)
+++ myfaces/core/trunk/impl/src/test/resources/org/apache/myfaces/view/facelets/tag/ui/s_page_decorate.xhtml Wed Jul 28 09:43:17 2010
@@ -0,0 +1,21 @@
+<!--
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+
+ $Id: s_page.xhtml,v 1.2 2008/07/13 19:01:38 rlubke Exp $
+-->
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
+ "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml" xmlns:ui="http://java.sun.com/jsf/facelets">
+
+<ui:composition template="s_layout.xhtml">BODY</ui:composition>
+</html>
\ No newline at end of file
Propchange: myfaces/core/trunk/impl/src/test/resources/org/apache/myfaces/view/facelets/tag/ui/s_page_decorate.xhtml
------------------------------------------------------------------------------
svn:eol-style = native
Propchange: myfaces/core/trunk/impl/src/test/resources/org/apache/myfaces/view/facelets/tag/ui/s_page_decorate.xhtml
------------------------------------------------------------------------------
svn:mime-type = text/plain
Added: myfaces/core/trunk/impl/src/test/resources/org/apache/myfaces/view/facelets/tag/ui/template_with_insert.xhtml
URL: http://svn.apache.org/viewvc/myfaces/core/trunk/impl/src/test/resources/org/apache/myfaces/view/facelets/tag/ui/template_with_insert.xhtml?rev=980006&view=auto
==============================================================================
--- myfaces/core/trunk/impl/src/test/resources/org/apache/myfaces/view/facelets/tag/ui/template_with_insert.xhtml (added)
+++ myfaces/core/trunk/impl/src/test/resources/org/apache/myfaces/view/facelets/tag/ui/template_with_insert.xhtml Wed Jul 28 09:43:17 2010
@@ -0,0 +1,22 @@
+<!--
+ Licensed to the Apache Software Foundation (ASF) under one or more
+ contributor license agreements. See the NOTICE file distributed with
+ this work for additional information regarding copyright ownership.
+ The ASF licenses this file to You under the Apache License, Version 2.0
+ (the "License"); you may not use this file except in compliance with
+ the License. You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+-->
+<html xmlns="http://www.w3.org/1999/xhtml"
+ xmlns:ui="http://java.sun.com/jsf/facelets">
+
+ <span><ui:insert name="content">default ui:insert content</ui:insert></span>
+
+</html>
Propchange: myfaces/core/trunk/impl/src/test/resources/org/apache/myfaces/view/facelets/tag/ui/template_with_insert.xhtml
------------------------------------------------------------------------------
svn:eol-style = native
Propchange: myfaces/core/trunk/impl/src/test/resources/org/apache/myfaces/view/facelets/tag/ui/template_with_insert.xhtml
------------------------------------------------------------------------------
svn:mime-type = text/plain