You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@myfaces.apache.org by lu...@apache.org on 2010/07/30 02:33:25 UTC

svn commit: r980615 [2/3] - in /myfaces/tomahawk/trunk/core20: ./ src/test/java/org/apache/myfaces/component/behavior/ src/test/java/org/apache/myfaces/component/html/ext/behavior/ src/test/java/org/apache/myfaces/custom/calendar/ src/test/java/org/apa...

Added: myfaces/tomahawk/trunk/core20/src/test/java/org/apache/myfaces/component/html/ext/behavior/HtmlSelectOneRadioClientBehaviorRendererTest.java
URL: http://svn.apache.org/viewvc/myfaces/tomahawk/trunk/core20/src/test/java/org/apache/myfaces/component/html/ext/behavior/HtmlSelectOneRadioClientBehaviorRendererTest.java?rev=980615&view=auto
==============================================================================
--- myfaces/tomahawk/trunk/core20/src/test/java/org/apache/myfaces/component/html/ext/behavior/HtmlSelectOneRadioClientBehaviorRendererTest.java (added)
+++ myfaces/tomahawk/trunk/core20/src/test/java/org/apache/myfaces/component/html/ext/behavior/HtmlSelectOneRadioClientBehaviorRendererTest.java Fri Jul 30 00:33:23 2010
@@ -0,0 +1,118 @@
+/*
+ * 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.
+ */
+package org.apache.myfaces.component.html.ext.behavior;
+
+import javax.faces.component.UIComponent;
+import javax.faces.component.UISelectItem;
+import javax.faces.component.behavior.AjaxBehavior;
+import javax.faces.component.behavior.ClientBehaviorHolder;
+
+import org.apache.myfaces.component.behavior.AbstractClientBehaviorTestCase;
+import org.apache.myfaces.component.behavior.HtmlClientEventAttributesUtil;
+import org.apache.myfaces.component.behavior.HtmlRenderedClientEventAttr;
+import org.apache.myfaces.component.html.ext.HtmlSelectOneRadio;
+import org.junit.Assert;
+
+/**
+ * @author Leonardo Uribe (latest modification by $Author: jankeesvanandel $)
+ * @version $Revision: 799929 $ $Date: 2009-08-01 16:29:33 -0500 (sáb, 01 ago 2009) $
+ */
+public class HtmlSelectOneRadioClientBehaviorRendererTest extends AbstractClientBehaviorTestCase
+{
+    private HtmlRenderedClientEventAttr[] attrs = null;
+    
+    @Override
+    public void setUp() throws Exception
+    {
+        super.setUp();
+        attrs = HtmlClientEventAttributesUtil.generateClientBehaviorInputEventAttrs();
+    }
+
+    @Override
+    public void tearDown() throws Exception
+    {
+        super.tearDown();
+        attrs = null;
+    }
+
+
+    @Override
+    protected UIComponent createComponentToTest()
+    {
+        UIComponent component = new HtmlSelectOneRadio();
+        UISelectItem item = new UISelectItem();
+        item.setItemValue("value1");
+        component.getChildren().add(item);
+        return component;
+    }
+
+    @Override
+    protected HtmlRenderedClientEventAttr[] getClientBehaviorHtmlRenderedAttributes()
+    {
+        return attrs;
+    }
+    
+    @Override
+    public void testClientBehaviorHolderRendersId() 
+    {
+        HtmlRenderedClientEventAttr[] attrs = getClientBehaviorHtmlRenderedAttributes();
+        
+        for (int i = 0; i < attrs.length; i++)
+        {
+            UIComponent component = createComponentToTest();
+            ClientBehaviorHolder clientBehaviorHolder = (ClientBehaviorHolder) component;
+            clientBehaviorHolder.addClientBehavior(attrs[i].getClientEvent(), new AjaxBehavior());
+            try 
+            {
+                component.encodeAll(facesContext);
+                String output = outputWriter.toString();
+                Assert.assertTrue(output.matches(".+ id=\".+\".+"));
+                outputWriter.reset();
+            }
+            catch (Exception e)
+            {
+                Assert.fail(e.getMessage());
+            }
+        }
+    }
+    
+    @Override
+    public void testClientBehaviorHolderRendersName() 
+    {
+        HtmlRenderedClientEventAttr[] attrs = getClientBehaviorHtmlRenderedAttributes();
+        
+        for (int i = 0; i < attrs.length; i++)
+        {
+            UIComponent component = createComponentToTest();
+            ClientBehaviorHolder clientBehaviorHolder = (ClientBehaviorHolder) component;
+            clientBehaviorHolder.addClientBehavior(attrs[i].getClientEvent(), new AjaxBehavior());
+            try 
+            {
+                component.encodeAll(facesContext);
+                String output = outputWriter.toString();
+                Assert.assertTrue(output.matches(".+ name=\".+\".+"));
+                outputWriter.reset();
+            }
+            catch (Exception e)
+            {
+                Assert.fail(e.getMessage());
+            }
+        }
+    }
+}

Added: myfaces/tomahawk/trunk/core20/src/test/java/org/apache/myfaces/component/html/ext/behavior/HtmlTextClientBehaviorRendererTest.java
URL: http://svn.apache.org/viewvc/myfaces/tomahawk/trunk/core20/src/test/java/org/apache/myfaces/component/html/ext/behavior/HtmlTextClientBehaviorRendererTest.java?rev=980615&view=auto
==============================================================================
--- myfaces/tomahawk/trunk/core20/src/test/java/org/apache/myfaces/component/html/ext/behavior/HtmlTextClientBehaviorRendererTest.java (added)
+++ myfaces/tomahawk/trunk/core20/src/test/java/org/apache/myfaces/component/html/ext/behavior/HtmlTextClientBehaviorRendererTest.java Fri Jul 30 00:33:23 2010
@@ -0,0 +1,62 @@
+/*
+ * 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.
+ */
+package org.apache.myfaces.component.html.ext.behavior;
+
+import javax.faces.component.UIComponent;
+
+import org.apache.myfaces.component.behavior.AbstractClientBehaviorTestCase;
+import org.apache.myfaces.component.behavior.HtmlClientEventAttributesUtil;
+import org.apache.myfaces.component.behavior.HtmlRenderedClientEventAttr;
+import org.apache.myfaces.component.html.ext.HtmlInputText;
+
+/**
+ * @author Leonardo Uribe (latest modification by $Author: jankeesvanandel $)
+ * @version $Revision: 799929 $ $Date: 2009-08-01 16:29:33 -0500 (sáb, 01 ago 2009) $
+ */
+public class HtmlTextClientBehaviorRendererTest extends AbstractClientBehaviorTestCase
+{
+    private HtmlRenderedClientEventAttr[] attrs = null;
+    
+    @Override
+    public void setUp() throws Exception
+    {
+        super.setUp();
+        attrs = HtmlClientEventAttributesUtil.generateClientBehaviorInputEventAttrs();
+    }
+
+    @Override
+    public void tearDown() throws Exception
+    {
+        super.tearDown();
+        attrs = null;
+    }
+
+
+    @Override
+    protected UIComponent createComponentToTest()
+    {
+        return new HtmlInputText();
+    }
+
+    @Override
+    protected HtmlRenderedClientEventAttr[] getClientBehaviorHtmlRenderedAttributes()
+    {
+        return attrs;
+    }
+}

Added: myfaces/tomahawk/trunk/core20/src/test/java/org/apache/myfaces/component/html/ext/behavior/HtmlTextareaClientBehaviorRendererTest.java
URL: http://svn.apache.org/viewvc/myfaces/tomahawk/trunk/core20/src/test/java/org/apache/myfaces/component/html/ext/behavior/HtmlTextareaClientBehaviorRendererTest.java?rev=980615&view=auto
==============================================================================
--- myfaces/tomahawk/trunk/core20/src/test/java/org/apache/myfaces/component/html/ext/behavior/HtmlTextareaClientBehaviorRendererTest.java (added)
+++ myfaces/tomahawk/trunk/core20/src/test/java/org/apache/myfaces/component/html/ext/behavior/HtmlTextareaClientBehaviorRendererTest.java Fri Jul 30 00:33:23 2010
@@ -0,0 +1,62 @@
+/*
+ * 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.
+ */
+package org.apache.myfaces.component.html.ext.behavior;
+
+import javax.faces.component.UIComponent;
+
+import org.apache.myfaces.component.behavior.AbstractClientBehaviorTestCase;
+import org.apache.myfaces.component.behavior.HtmlClientEventAttributesUtil;
+import org.apache.myfaces.component.behavior.HtmlRenderedClientEventAttr;
+import org.apache.myfaces.component.html.ext.HtmlInputTextarea;
+
+/**
+ * @author Leonardo Uribe (latest modification by $Author: jankeesvanandel $)
+ * @version $Revision: 799929 $ $Date: 2009-08-01 16:29:33 -0500 (sáb, 01 ago 2009) $
+ */
+public class HtmlTextareaClientBehaviorRendererTest extends AbstractClientBehaviorTestCase
+{
+    private HtmlRenderedClientEventAttr[] attrs = null;
+    
+    @Override
+    public void setUp() throws Exception
+    {
+        super.setUp();
+        attrs = HtmlClientEventAttributesUtil.generateClientBehaviorInputEventAttrs();
+    }
+
+    @Override
+    public void tearDown() throws Exception
+    {
+        super.tearDown();
+        attrs = null;
+    }
+
+
+    @Override
+    protected UIComponent createComponentToTest()
+    {
+        return new HtmlInputTextarea();
+    }
+
+    @Override
+    protected HtmlRenderedClientEventAttr[] getClientBehaviorHtmlRenderedAttributes()
+    {
+        return attrs;
+    }
+}

Added: myfaces/tomahawk/trunk/core20/src/test/java/org/apache/myfaces/custom/calendar/HtmlCalendarInlineClientBehaviorRendererTest.java
URL: http://svn.apache.org/viewvc/myfaces/tomahawk/trunk/core20/src/test/java/org/apache/myfaces/custom/calendar/HtmlCalendarInlineClientBehaviorRendererTest.java?rev=980615&view=auto
==============================================================================
--- myfaces/tomahawk/trunk/core20/src/test/java/org/apache/myfaces/custom/calendar/HtmlCalendarInlineClientBehaviorRendererTest.java (added)
+++ myfaces/tomahawk/trunk/core20/src/test/java/org/apache/myfaces/custom/calendar/HtmlCalendarInlineClientBehaviorRendererTest.java Fri Jul 30 00:33:23 2010
@@ -0,0 +1,93 @@
+/*
+ * 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.
+ */
+package org.apache.myfaces.custom.calendar;
+
+import javax.faces.component.UIComponent;
+import javax.faces.component.html.HtmlForm;
+
+import org.apache.myfaces.component.behavior.AbstractClientBehaviorTestCase;
+import org.apache.myfaces.component.behavior.HtmlClientEventAttributesUtil;
+import org.apache.myfaces.component.behavior.HtmlRenderedClientEventAttr;
+import org.apache.myfaces.custom.calendar.HtmlInputCalendar;
+import org.apache.myfaces.shared_impl.renderkit.ClientBehaviorEvents;
+import org.apache.myfaces.shared_impl.renderkit.html.HTML;
+import org.junit.Ignore;
+import org.junit.Test;
+
+/**
+ * @author Leonardo Uribe (latest modification by $Author: jankeesvanandel $)
+ * @version $Revision: 799929 $ $Date: 2009-08-01 16:29:33 -0500 (sáb, 01 ago 2009) $
+ */
+public class HtmlCalendarInlineClientBehaviorRendererTest extends AbstractClientBehaviorTestCase
+{
+    private HtmlRenderedClientEventAttr[] attrs = null;
+    
+    @Override
+    public void setUp() throws Exception
+    {
+        super.setUp();
+        attrs = (HtmlRenderedClientEventAttr[]) 
+            org.apache.myfaces.shared_impl.util.ArrayUtils.concat( 
+                    HtmlClientEventAttributesUtil.generateClientBehaviorEventAttrs(),
+                new HtmlRenderedClientEventAttr[]{
+                    new HtmlRenderedClientEventAttr(HTML.ONBLUR_ATTR, ClientBehaviorEvents.BLUR),
+                    new HtmlRenderedClientEventAttr(HTML.ONFOCUS_ATTR, ClientBehaviorEvents.FOCUS)
+                });
+    }
+
+    @Override
+    protected void setUpServletObjects() throws Exception
+    {
+        // TODO Auto-generated method stub
+        super.setUpServletObjects();
+        request.setAttribute("org.apache.MyFaces.FIRST_SUBMIT_SCRIPT_ON_PAGE", Boolean.FALSE);
+    }
+
+    @Override
+    public void tearDown() throws Exception
+    {
+        super.tearDown();
+        attrs = null;
+    }
+
+
+    @Override
+    protected UIComponent createComponentToTest()
+    {
+        HtmlInputCalendar calendar = new HtmlInputCalendar();
+        UIComponent form = new HtmlForm();
+        form.getChildren().add(calendar);
+        facesContext.getViewRoot().getChildren().add(form);
+        return calendar;
+    }
+
+    @Override
+    protected HtmlRenderedClientEventAttr[] getClientBehaviorHtmlRenderedAttributes()
+    {
+        return attrs;
+    }
+
+    @Test
+    @Ignore
+    @Override
+    public void testClientBehaviorHolderRendersName()
+    {
+        super.testClientBehaviorHolderRendersName();
+    }
+}

Added: myfaces/tomahawk/trunk/core20/src/test/java/org/apache/myfaces/custom/calendar/HtmlCalendarPopupClientBehaviorRendererTest.java
URL: http://svn.apache.org/viewvc/myfaces/tomahawk/trunk/core20/src/test/java/org/apache/myfaces/custom/calendar/HtmlCalendarPopupClientBehaviorRendererTest.java?rev=980615&view=auto
==============================================================================
--- myfaces/tomahawk/trunk/core20/src/test/java/org/apache/myfaces/custom/calendar/HtmlCalendarPopupClientBehaviorRendererTest.java (added)
+++ myfaces/tomahawk/trunk/core20/src/test/java/org/apache/myfaces/custom/calendar/HtmlCalendarPopupClientBehaviorRendererTest.java Fri Jul 30 00:33:23 2010
@@ -0,0 +1,88 @@
+/*
+ * 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.
+ */
+package org.apache.myfaces.custom.calendar;
+
+import javax.faces.component.UIComponent;
+import javax.faces.component.html.HtmlForm;
+
+import org.apache.myfaces.component.behavior.AbstractClientBehaviorTestCase;
+import org.apache.myfaces.component.behavior.HtmlClientEventAttributesUtil;
+import org.apache.myfaces.component.behavior.HtmlRenderedClientEventAttr;
+import org.apache.myfaces.custom.calendar.HtmlInputCalendar;
+import org.apache.myfaces.shared_impl.renderkit.ClientBehaviorEvents;
+import org.apache.myfaces.shared_impl.renderkit.html.HTML;
+import org.junit.Ignore;
+import org.junit.Test;
+
+/**
+ * @author Leonardo Uribe (latest modification by $Author: jankeesvanandel $)
+ * @version $Revision: 799929 $ $Date: 2009-08-01 16:29:33 -0500 (sáb, 01 ago 2009) $
+ */
+public class HtmlCalendarPopupClientBehaviorRendererTest extends AbstractClientBehaviorTestCase
+{
+    private HtmlRenderedClientEventAttr[] attrs = null;
+    
+    @Override
+    public void setUp() throws Exception
+    {
+        super.setUp();
+        attrs = HtmlClientEventAttributesUtil.generateClientBehaviorInputEventAttrs();
+    }
+
+    @Override
+    protected void setUpServletObjects() throws Exception
+    {
+        // TODO Auto-generated method stub
+        super.setUpServletObjects();
+        request.setAttribute("org.apache.MyFaces.FIRST_SUBMIT_SCRIPT_ON_PAGE", Boolean.FALSE);
+    }
+
+    @Override
+    public void tearDown() throws Exception
+    {
+        super.tearDown();
+        attrs = null;
+    }
+
+
+    @Override
+    protected UIComponent createComponentToTest()
+    {
+        HtmlInputCalendar calendar = new HtmlInputCalendar();
+        calendar.setRenderAsPopup(true);
+        UIComponent form = new HtmlForm();
+        form.getChildren().add(calendar);
+        facesContext.getViewRoot().getChildren().add(form);
+        return calendar;
+    }
+
+    @Override
+    protected HtmlRenderedClientEventAttr[] getClientBehaviorHtmlRenderedAttributes()
+    {
+        return attrs;
+    }
+
+    @Test
+    @Ignore
+    @Override
+    public void testClientBehaviorHolderRendersName()
+    {
+        super.testClientBehaviorHolderRendersName();
+    }
+}

Added: myfaces/tomahawk/trunk/core20/src/test/java/org/apache/myfaces/custom/datalist/HtmlDataListGridClientBehaviorRendererTest.java
URL: http://svn.apache.org/viewvc/myfaces/tomahawk/trunk/core20/src/test/java/org/apache/myfaces/custom/datalist/HtmlDataListGridClientBehaviorRendererTest.java?rev=980615&view=auto
==============================================================================
--- myfaces/tomahawk/trunk/core20/src/test/java/org/apache/myfaces/custom/datalist/HtmlDataListGridClientBehaviorRendererTest.java (added)
+++ myfaces/tomahawk/trunk/core20/src/test/java/org/apache/myfaces/custom/datalist/HtmlDataListGridClientBehaviorRendererTest.java Fri Jul 30 00:33:23 2010
@@ -0,0 +1,74 @@
+/*
+ * 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.
+ */
+package org.apache.myfaces.custom.datalist;
+
+import javax.faces.component.UIComponent;
+
+import org.apache.myfaces.component.behavior.AbstractClientBehaviorTestCase;
+import org.apache.myfaces.component.behavior.HtmlClientEventAttributesUtil;
+import org.apache.myfaces.component.behavior.HtmlRenderedClientEventAttr;
+import org.junit.Ignore;
+import org.junit.Test;
+
+/**
+ * @author Leonardo Uribe (latest modification by $Author: jankeesvanandel $)
+ * @version $Revision: 799929 $ $Date: 2009-08-01 16:29:33 -0500 (sáb, 01 ago 2009) $
+ */
+public class HtmlDataListGridClientBehaviorRendererTest extends AbstractClientBehaviorTestCase
+{
+    private HtmlRenderedClientEventAttr[] attrs = null;
+    
+    @Override
+    public void setUp() throws Exception
+    {
+        super.setUp();
+        attrs = HtmlClientEventAttributesUtil.generateClientBehaviorEventAttrs();
+    }
+
+    @Override
+    public void tearDown() throws Exception
+    {
+        super.tearDown();
+        attrs = null;
+    }
+
+
+    @Override
+    protected UIComponent createComponentToTest()
+    {
+        HtmlDataList dataList = new HtmlDataList();
+        dataList.setLayout(HtmlListRenderer.LAYOUT_GRID);
+        return dataList;
+    }
+
+    @Override
+    protected HtmlRenderedClientEventAttr[] getClientBehaviorHtmlRenderedAttributes()
+    {
+        return attrs;
+    }
+    
+    @Ignore
+    @Test
+    @Override
+    public void testClientBehaviorHolderRendersName() 
+    {
+        super.testClientBehaviorHolderRendersName();
+    }
+    
+}

Added: myfaces/tomahawk/trunk/core20/src/test/java/org/apache/myfaces/custom/datalist/HtmlDataListOLClientBehaviorRendererTest.java
URL: http://svn.apache.org/viewvc/myfaces/tomahawk/trunk/core20/src/test/java/org/apache/myfaces/custom/datalist/HtmlDataListOLClientBehaviorRendererTest.java?rev=980615&view=auto
==============================================================================
--- myfaces/tomahawk/trunk/core20/src/test/java/org/apache/myfaces/custom/datalist/HtmlDataListOLClientBehaviorRendererTest.java (added)
+++ myfaces/tomahawk/trunk/core20/src/test/java/org/apache/myfaces/custom/datalist/HtmlDataListOLClientBehaviorRendererTest.java Fri Jul 30 00:33:23 2010
@@ -0,0 +1,74 @@
+/*
+ * 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.
+ */
+package org.apache.myfaces.custom.datalist;
+
+import javax.faces.component.UIComponent;
+
+import org.apache.myfaces.component.behavior.AbstractClientBehaviorTestCase;
+import org.apache.myfaces.component.behavior.HtmlClientEventAttributesUtil;
+import org.apache.myfaces.component.behavior.HtmlRenderedClientEventAttr;
+import org.junit.Ignore;
+import org.junit.Test;
+
+/**
+ * @author Leonardo Uribe (latest modification by $Author: jankeesvanandel $)
+ * @version $Revision: 799929 $ $Date: 2009-08-01 16:29:33 -0500 (sáb, 01 ago 2009) $
+ */
+public class HtmlDataListOLClientBehaviorRendererTest extends AbstractClientBehaviorTestCase
+{
+    private HtmlRenderedClientEventAttr[] attrs = null;
+    
+    @Override
+    public void setUp() throws Exception
+    {
+        super.setUp();
+        attrs = HtmlClientEventAttributesUtil.generateClientBehaviorEventAttrs();
+    }
+
+    @Override
+    public void tearDown() throws Exception
+    {
+        super.tearDown();
+        attrs = null;
+    }
+
+
+    @Override
+    protected UIComponent createComponentToTest()
+    {
+        HtmlDataList dataList = new HtmlDataList();
+        dataList.setLayout(HtmlListRenderer.LAYOUT_OL);
+        return dataList;
+    }
+
+    @Override
+    protected HtmlRenderedClientEventAttr[] getClientBehaviorHtmlRenderedAttributes()
+    {
+        return attrs;
+    }
+    
+    @Ignore
+    @Test
+    @Override
+    public void testClientBehaviorHolderRendersName() 
+    {
+        super.testClientBehaviorHolderRendersName();
+    }
+    
+}

Added: myfaces/tomahawk/trunk/core20/src/test/java/org/apache/myfaces/custom/datalist/HtmlDataListSimpleClientBehaviorRendererTest.java
URL: http://svn.apache.org/viewvc/myfaces/tomahawk/trunk/core20/src/test/java/org/apache/myfaces/custom/datalist/HtmlDataListSimpleClientBehaviorRendererTest.java?rev=980615&view=auto
==============================================================================
--- myfaces/tomahawk/trunk/core20/src/test/java/org/apache/myfaces/custom/datalist/HtmlDataListSimpleClientBehaviorRendererTest.java (added)
+++ myfaces/tomahawk/trunk/core20/src/test/java/org/apache/myfaces/custom/datalist/HtmlDataListSimpleClientBehaviorRendererTest.java Fri Jul 30 00:33:23 2010
@@ -0,0 +1,74 @@
+/*
+ * 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.
+ */
+package org.apache.myfaces.custom.datalist;
+
+import javax.faces.component.UIComponent;
+
+import org.apache.myfaces.component.behavior.AbstractClientBehaviorTestCase;
+import org.apache.myfaces.component.behavior.HtmlClientEventAttributesUtil;
+import org.apache.myfaces.component.behavior.HtmlRenderedClientEventAttr;
+import org.junit.Ignore;
+import org.junit.Test;
+
+/**
+ * @author Leonardo Uribe (latest modification by $Author: jankeesvanandel $)
+ * @version $Revision: 799929 $ $Date: 2009-08-01 16:29:33 -0500 (sáb, 01 ago 2009) $
+ */
+public class HtmlDataListSimpleClientBehaviorRendererTest extends AbstractClientBehaviorTestCase
+{
+    private HtmlRenderedClientEventAttr[] attrs = null;
+    
+    @Override
+    public void setUp() throws Exception
+    {
+        super.setUp();
+        attrs = HtmlClientEventAttributesUtil.generateClientBehaviorEventAttrs();
+    }
+
+    @Override
+    public void tearDown() throws Exception
+    {
+        super.tearDown();
+        attrs = null;
+    }
+
+
+    @Override
+    protected UIComponent createComponentToTest()
+    {
+        HtmlDataList dataList = new HtmlDataList();
+        dataList.setLayout(HtmlListRenderer.LAYOUT_SIMPLE);
+        return dataList;
+    }
+
+    @Override
+    protected HtmlRenderedClientEventAttr[] getClientBehaviorHtmlRenderedAttributes()
+    {
+        return attrs;
+    }
+    
+    @Ignore
+    @Test
+    @Override
+    public void testClientBehaviorHolderRendersName() 
+    {
+        super.testClientBehaviorHolderRendersName();
+    }
+    
+}

Added: myfaces/tomahawk/trunk/core20/src/test/java/org/apache/myfaces/custom/datalist/HtmlDataListULClientBehaviorRendererTest.java
URL: http://svn.apache.org/viewvc/myfaces/tomahawk/trunk/core20/src/test/java/org/apache/myfaces/custom/datalist/HtmlDataListULClientBehaviorRendererTest.java?rev=980615&view=auto
==============================================================================
--- myfaces/tomahawk/trunk/core20/src/test/java/org/apache/myfaces/custom/datalist/HtmlDataListULClientBehaviorRendererTest.java (added)
+++ myfaces/tomahawk/trunk/core20/src/test/java/org/apache/myfaces/custom/datalist/HtmlDataListULClientBehaviorRendererTest.java Fri Jul 30 00:33:23 2010
@@ -0,0 +1,74 @@
+/*
+ * 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.
+ */
+package org.apache.myfaces.custom.datalist;
+
+import javax.faces.component.UIComponent;
+
+import org.apache.myfaces.component.behavior.AbstractClientBehaviorTestCase;
+import org.apache.myfaces.component.behavior.HtmlClientEventAttributesUtil;
+import org.apache.myfaces.component.behavior.HtmlRenderedClientEventAttr;
+import org.junit.Ignore;
+import org.junit.Test;
+
+/**
+ * @author Leonardo Uribe (latest modification by $Author: jankeesvanandel $)
+ * @version $Revision: 799929 $ $Date: 2009-08-01 16:29:33 -0500 (sáb, 01 ago 2009) $
+ */
+public class HtmlDataListULClientBehaviorRendererTest extends AbstractClientBehaviorTestCase
+{
+    private HtmlRenderedClientEventAttr[] attrs = null;
+    
+    @Override
+    public void setUp() throws Exception
+    {
+        super.setUp();
+        attrs = HtmlClientEventAttributesUtil.generateClientBehaviorEventAttrs();
+    }
+
+    @Override
+    public void tearDown() throws Exception
+    {
+        super.tearDown();
+        attrs = null;
+    }
+
+
+    @Override
+    protected UIComponent createComponentToTest()
+    {
+        HtmlDataList dataList = new HtmlDataList();
+        dataList.setLayout(HtmlListRenderer.LAYOUT_UL);
+        return dataList;
+    }
+
+    @Override
+    protected HtmlRenderedClientEventAttr[] getClientBehaviorHtmlRenderedAttributes()
+    {
+        return attrs;
+    }
+    
+    @Ignore
+    @Test
+    @Override
+    public void testClientBehaviorHolderRendersName() 
+    {
+        super.testClientBehaviorHolderRendersName();
+    }
+    
+}

Added: myfaces/tomahawk/trunk/core20/src/test/java/org/apache/myfaces/custom/date/HtmlDateClientBehaviorRendererTest.java
URL: http://svn.apache.org/viewvc/myfaces/tomahawk/trunk/core20/src/test/java/org/apache/myfaces/custom/date/HtmlDateClientBehaviorRendererTest.java?rev=980615&view=auto
==============================================================================
--- myfaces/tomahawk/trunk/core20/src/test/java/org/apache/myfaces/custom/date/HtmlDateClientBehaviorRendererTest.java (added)
+++ myfaces/tomahawk/trunk/core20/src/test/java/org/apache/myfaces/custom/date/HtmlDateClientBehaviorRendererTest.java Fri Jul 30 00:33:23 2010
@@ -0,0 +1,84 @@
+/*
+ * 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.
+ */
+package org.apache.myfaces.custom.date;
+
+import javax.faces.component.UIComponent;
+import javax.faces.component.html.HtmlForm;
+
+import org.apache.myfaces.component.behavior.AbstractClientBehaviorTestCase;
+import org.apache.myfaces.component.behavior.HtmlClientEventAttributesUtil;
+import org.apache.myfaces.component.behavior.HtmlRenderedClientEventAttr;
+import org.junit.Ignore;
+import org.junit.Test;
+
+/**
+ * @author Leonardo Uribe (latest modification by $Author: jankeesvanandel $)
+ * @version $Revision: 799929 $ $Date: 2009-08-01 16:29:33 -0500 (sáb, 01 ago 2009) $
+ */
+public class HtmlDateClientBehaviorRendererTest extends AbstractClientBehaviorTestCase
+{
+    private HtmlRenderedClientEventAttr[] attrs = null;
+    
+    @Override
+    public void setUp() throws Exception
+    {
+        super.setUp();
+        attrs = HtmlClientEventAttributesUtil.generateClientBehaviorInputEventAttrs();
+    }
+
+    @Override
+    protected void setUpServletObjects() throws Exception
+    {
+        // TODO Auto-generated method stub
+        super.setUpServletObjects();
+        request.setAttribute("org.apache.MyFaces.FIRST_SUBMIT_SCRIPT_ON_PAGE", Boolean.FALSE);
+    }
+
+    @Override
+    public void tearDown() throws Exception
+    {
+        super.tearDown();
+        attrs = null;
+    }
+
+
+    @Override
+    protected UIComponent createComponentToTest()
+    {
+        HtmlInputDate calendar = new HtmlInputDate();
+        UIComponent form = new HtmlForm();
+        form.getChildren().add(calendar);
+        facesContext.getViewRoot().getChildren().add(form);
+        return calendar;
+    }
+
+    @Override
+    protected HtmlRenderedClientEventAttr[] getClientBehaviorHtmlRenderedAttributes()
+    {
+        return attrs;
+    }
+
+    @Test
+    @Ignore
+    @Override
+    public void testClientBehaviorHolderRendersName()
+    {
+        super.testClientBehaviorHolderRendersName();
+    }
+}

Added: myfaces/tomahawk/trunk/core20/src/test/java/org/apache/myfaces/custom/div/DivClientBehaviorTest.java
URL: http://svn.apache.org/viewvc/myfaces/tomahawk/trunk/core20/src/test/java/org/apache/myfaces/custom/div/DivClientBehaviorTest.java?rev=980615&view=auto
==============================================================================
--- myfaces/tomahawk/trunk/core20/src/test/java/org/apache/myfaces/custom/div/DivClientBehaviorTest.java (added)
+++ myfaces/tomahawk/trunk/core20/src/test/java/org/apache/myfaces/custom/div/DivClientBehaviorTest.java Fri Jul 30 00:33:23 2010
@@ -0,0 +1,57 @@
+/*
+ * 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.
+ */
+package org.apache.myfaces.custom.div;
+
+import javax.faces.component.UIComponent;
+
+import org.apache.myfaces.component.behavior.AbstractClientBehaviorTestCase;
+import org.apache.myfaces.component.behavior.HtmlClientEventAttributesUtil;
+import org.apache.myfaces.component.behavior.HtmlRenderedClientEventAttr;
+
+
+public class DivClientBehaviorTest extends AbstractClientBehaviorTestCase
+{
+    private HtmlRenderedClientEventAttr[] attrs = null;
+    
+    @Override
+    public void setUp() throws Exception
+    {
+        super.setUp();
+        attrs = HtmlClientEventAttributesUtil.generateClientBehaviorEventAttrs();
+    }
+
+    @Override
+    public void tearDown() throws Exception
+    {
+        super.tearDown();
+        attrs = null;
+    }
+
+    @Override
+    protected UIComponent createComponentToTest()
+    {
+        return new Div();
+    }
+
+    @Override
+    protected HtmlRenderedClientEventAttr[] getClientBehaviorHtmlRenderedAttributes()
+    {
+        return attrs;
+    }
+}

Added: myfaces/tomahawk/trunk/core20/src/test/java/org/apache/myfaces/custom/document/DocumentBodyClientBehaviorRendererTest.java
URL: http://svn.apache.org/viewvc/myfaces/tomahawk/trunk/core20/src/test/java/org/apache/myfaces/custom/document/DocumentBodyClientBehaviorRendererTest.java?rev=980615&view=auto
==============================================================================
--- myfaces/tomahawk/trunk/core20/src/test/java/org/apache/myfaces/custom/document/DocumentBodyClientBehaviorRendererTest.java (added)
+++ myfaces/tomahawk/trunk/core20/src/test/java/org/apache/myfaces/custom/document/DocumentBodyClientBehaviorRendererTest.java Fri Jul 30 00:33:23 2010
@@ -0,0 +1,83 @@
+/*
+ * 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.
+ */
+package org.apache.myfaces.custom.document;
+
+import javax.faces.component.UIComponent;
+
+import org.apache.myfaces.component.behavior.AbstractClientBehaviorTestCase;
+import org.apache.myfaces.component.behavior.HtmlClientEventAttributesUtil;
+import org.apache.myfaces.component.behavior.HtmlRenderedClientEventAttr;
+import org.apache.myfaces.shared_impl.renderkit.ClientBehaviorEvents;
+import org.apache.myfaces.shared_impl.renderkit.html.HTML;
+import org.junit.Ignore;
+import org.junit.Test;
+
+/**
+ * @author Leonardo Uribe (latest modification by $Author: jankeesvanandel $)
+ * @version $Revision: 799929 $ $Date: 2009-08-01 16:29:33 -0500 (sáb, 01 ago 2009) $
+ */
+public class DocumentBodyClientBehaviorRendererTest extends AbstractClientBehaviorTestCase
+{
+    private HtmlRenderedClientEventAttr[] attrs = null;
+    
+    @Override
+    public void setUp() throws Exception
+    {
+        super.setUp();
+        attrs = (HtmlRenderedClientEventAttr[]) 
+            org.apache.myfaces.shared_impl.util.ArrayUtils.concat( 
+                    HtmlClientEventAttributesUtil.generateClientBehaviorEventAttrs(),
+                new HtmlRenderedClientEventAttr[]{
+                    new HtmlRenderedClientEventAttr(HTML.ONLOAD_ATTR, ClientBehaviorEvents.LOAD),
+                    new HtmlRenderedClientEventAttr(HTML.ONUNLOAD_ATTR, ClientBehaviorEvents.UNLOAD)
+                });
+    }
+
+    @Override
+    public void tearDown() throws Exception
+    {
+        super.tearDown();
+        attrs = null;
+    }
+
+    @Override
+    protected UIComponent createComponentToTest()
+    {
+        return new DocumentBody();
+    }
+
+    @Override
+    protected HtmlRenderedClientEventAttr[] getClientBehaviorHtmlRenderedAttributes()
+    {
+        return attrs;
+    }
+    
+    /**
+     * Components that render client behaviors should always render "id" and "name" attribute
+     * <body> does not have "name", so we just need to check "id"
+     */
+    @Test
+    @Ignore
+    @Override
+    public void testClientBehaviorHolderRendersName() 
+    {
+        super.testClientBehaviorHolderRendersName();
+    }
+
+}

Added: myfaces/tomahawk/trunk/core20/src/test/java/org/apache/myfaces/custom/fileupload/HtmlFileUploadClientBehaviorRendererTest.java
URL: http://svn.apache.org/viewvc/myfaces/tomahawk/trunk/core20/src/test/java/org/apache/myfaces/custom/fileupload/HtmlFileUploadClientBehaviorRendererTest.java?rev=980615&view=auto
==============================================================================
--- myfaces/tomahawk/trunk/core20/src/test/java/org/apache/myfaces/custom/fileupload/HtmlFileUploadClientBehaviorRendererTest.java (added)
+++ myfaces/tomahawk/trunk/core20/src/test/java/org/apache/myfaces/custom/fileupload/HtmlFileUploadClientBehaviorRendererTest.java Fri Jul 30 00:33:23 2010
@@ -0,0 +1,61 @@
+/*
+ * 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.
+ */
+package org.apache.myfaces.custom.fileupload;
+
+import javax.faces.component.UIComponent;
+
+import org.apache.myfaces.component.behavior.AbstractClientBehaviorTestCase;
+import org.apache.myfaces.component.behavior.HtmlClientEventAttributesUtil;
+import org.apache.myfaces.component.behavior.HtmlRenderedClientEventAttr;
+
+/**
+ * @author Leonardo Uribe (latest modification by $Author: jankeesvanandel $)
+ * @version $Revision: 799929 $ $Date: 2009-08-01 16:29:33 -0500 (sáb, 01 ago 2009) $
+ */
+public class HtmlFileUploadClientBehaviorRendererTest extends AbstractClientBehaviorTestCase
+{
+    private HtmlRenderedClientEventAttr[] attrs = null;
+    
+    @Override
+    public void setUp() throws Exception
+    {
+        super.setUp();
+        attrs = HtmlClientEventAttributesUtil.generateClientBehaviorInputEventAttrs();
+    }
+
+    @Override
+    public void tearDown() throws Exception
+    {
+        super.tearDown();
+        attrs = null;
+    }
+
+
+    @Override
+    protected UIComponent createComponentToTest()
+    {
+        return new HtmlInputFileUpload();
+    }
+
+    @Override
+    protected HtmlRenderedClientEventAttr[] getClientBehaviorHtmlRenderedAttributes()
+    {
+        return attrs;
+    }
+}

Added: myfaces/tomahawk/trunk/core20/src/test/java/org/apache/myfaces/custom/inputTextHelp/HtmlTextHelpClientBehaviorHelpTextRendererTest.java
URL: http://svn.apache.org/viewvc/myfaces/tomahawk/trunk/core20/src/test/java/org/apache/myfaces/custom/inputTextHelp/HtmlTextHelpClientBehaviorHelpTextRendererTest.java?rev=980615&view=auto
==============================================================================
--- myfaces/tomahawk/trunk/core20/src/test/java/org/apache/myfaces/custom/inputTextHelp/HtmlTextHelpClientBehaviorHelpTextRendererTest.java (added)
+++ myfaces/tomahawk/trunk/core20/src/test/java/org/apache/myfaces/custom/inputTextHelp/HtmlTextHelpClientBehaviorHelpTextRendererTest.java Fri Jul 30 00:33:23 2010
@@ -0,0 +1,64 @@
+/*
+ * 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.
+ */
+package org.apache.myfaces.custom.inputTextHelp;
+
+import javax.faces.component.UIComponent;
+
+import org.apache.myfaces.component.behavior.AbstractClientBehaviorTestCase;
+import org.apache.myfaces.component.behavior.HtmlClientEventAttributesUtil;
+import org.apache.myfaces.component.behavior.HtmlRenderedClientEventAttr;
+import org.apache.myfaces.component.html.ext.HtmlInputText;
+
+/**
+ * @author Leonardo Uribe (latest modification by $Author: jankeesvanandel $)
+ * @version $Revision: 799929 $ $Date: 2009-08-01 16:29:33 -0500 (sáb, 01 ago 2009) $
+ */
+public class HtmlTextHelpClientBehaviorHelpTextRendererTest extends AbstractClientBehaviorTestCase
+{
+    private HtmlRenderedClientEventAttr[] attrs = null;
+    
+    @Override
+    public void setUp() throws Exception
+    {
+        super.setUp();
+        attrs = HtmlClientEventAttributesUtil.generateClientBehaviorInputEventAttrs();
+    }
+
+    @Override
+    public void tearDown() throws Exception
+    {
+        super.tearDown();
+        attrs = null;
+    }
+
+
+    @Override
+    protected UIComponent createComponentToTest()
+    {
+        HtmlInputTextHelp it = new HtmlInputTextHelp();
+        it.setHelpText("YYYY-MM-DD");
+        return it;
+    }
+
+    @Override
+    protected HtmlRenderedClientEventAttr[] getClientBehaviorHtmlRenderedAttributes()
+    {
+        return attrs;
+    }
+}

Added: myfaces/tomahawk/trunk/core20/src/test/java/org/apache/myfaces/custom/inputTextHelp/HtmlTextHelpClientBehaviorRendererTest.java
URL: http://svn.apache.org/viewvc/myfaces/tomahawk/trunk/core20/src/test/java/org/apache/myfaces/custom/inputTextHelp/HtmlTextHelpClientBehaviorRendererTest.java?rev=980615&view=auto
==============================================================================
--- myfaces/tomahawk/trunk/core20/src/test/java/org/apache/myfaces/custom/inputTextHelp/HtmlTextHelpClientBehaviorRendererTest.java (added)
+++ myfaces/tomahawk/trunk/core20/src/test/java/org/apache/myfaces/custom/inputTextHelp/HtmlTextHelpClientBehaviorRendererTest.java Fri Jul 30 00:33:23 2010
@@ -0,0 +1,62 @@
+/*
+ * 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.
+ */
+package org.apache.myfaces.custom.inputTextHelp;
+
+import javax.faces.component.UIComponent;
+
+import org.apache.myfaces.component.behavior.AbstractClientBehaviorTestCase;
+import org.apache.myfaces.component.behavior.HtmlClientEventAttributesUtil;
+import org.apache.myfaces.component.behavior.HtmlRenderedClientEventAttr;
+import org.apache.myfaces.component.html.ext.HtmlInputText;
+
+/**
+ * @author Leonardo Uribe (latest modification by $Author: jankeesvanandel $)
+ * @version $Revision: 799929 $ $Date: 2009-08-01 16:29:33 -0500 (sáb, 01 ago 2009) $
+ */
+public class HtmlTextHelpClientBehaviorRendererTest extends AbstractClientBehaviorTestCase
+{
+    private HtmlRenderedClientEventAttr[] attrs = null;
+    
+    @Override
+    public void setUp() throws Exception
+    {
+        super.setUp();
+        attrs = HtmlClientEventAttributesUtil.generateClientBehaviorInputEventAttrs();
+    }
+
+    @Override
+    public void tearDown() throws Exception
+    {
+        super.tearDown();
+        attrs = null;
+    }
+
+
+    @Override
+    protected UIComponent createComponentToTest()
+    {
+        return new HtmlInputTextHelp();
+    }
+
+    @Override
+    protected HtmlRenderedClientEventAttr[] getClientBehaviorHtmlRenderedAttributes()
+    {
+        return attrs;
+    }
+}

Added: myfaces/tomahawk/trunk/core20/src/test/java/org/apache/myfaces/custom/layout/HtmlLayoutClientBehaviorRendererTest.java
URL: http://svn.apache.org/viewvc/myfaces/tomahawk/trunk/core20/src/test/java/org/apache/myfaces/custom/layout/HtmlLayoutClientBehaviorRendererTest.java?rev=980615&view=auto
==============================================================================
--- myfaces/tomahawk/trunk/core20/src/test/java/org/apache/myfaces/custom/layout/HtmlLayoutClientBehaviorRendererTest.java (added)
+++ myfaces/tomahawk/trunk/core20/src/test/java/org/apache/myfaces/custom/layout/HtmlLayoutClientBehaviorRendererTest.java Fri Jul 30 00:33:23 2010
@@ -0,0 +1,74 @@
+/*
+ * 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.
+ */
+package org.apache.myfaces.custom.layout;
+
+import javax.faces.component.UIComponent;
+
+import org.apache.myfaces.component.behavior.AbstractClientBehaviorTestCase;
+import org.apache.myfaces.component.behavior.HtmlClientEventAttributesUtil;
+import org.apache.myfaces.component.behavior.HtmlRenderedClientEventAttr;
+import org.apache.myfaces.component.html.ext.HtmlPanelGrid;
+import org.junit.Ignore;
+import org.junit.Test;
+
+/**
+ * @author Leonardo Uribe (latest modification by $Author: jankeesvanandel $)
+ * @version $Revision: 799929 $ $Date: 2009-08-01 16:29:33 -0500 (sáb, 01 ago 2009) $
+ */
+public class HtmlLayoutClientBehaviorRendererTest extends AbstractClientBehaviorTestCase
+{
+    private HtmlRenderedClientEventAttr[] attrs = null;
+    
+    @Override
+    public void setUp() throws Exception
+    {
+        super.setUp();
+        attrs = HtmlClientEventAttributesUtil.generateClientBehaviorEventAttrs();
+    }
+
+    @Override
+    public void tearDown() throws Exception
+    {
+        super.tearDown();
+        attrs = null;
+    }
+
+
+    @Override
+    protected UIComponent createComponentToTest()
+    {
+        HtmlPanelLayout panelLayout = new HtmlPanelLayout();
+        panelLayout.setLayout("classic");
+        return panelLayout;
+    }
+
+    @Override
+    protected HtmlRenderedClientEventAttr[] getClientBehaviorHtmlRenderedAttributes()
+    {
+        return attrs;
+    }
+    
+    @Ignore
+    @Test
+    @Override
+    public void testClientBehaviorHolderRendersName() 
+    {
+        super.testClientBehaviorHolderRendersName();
+    }
+}

Added: myfaces/tomahawk/trunk/core20/src/test/java/org/apache/myfaces/custom/layout/HtmlLayoutNavRightClientBehaviorRendererTest.java
URL: http://svn.apache.org/viewvc/myfaces/tomahawk/trunk/core20/src/test/java/org/apache/myfaces/custom/layout/HtmlLayoutNavRightClientBehaviorRendererTest.java?rev=980615&view=auto
==============================================================================
--- myfaces/tomahawk/trunk/core20/src/test/java/org/apache/myfaces/custom/layout/HtmlLayoutNavRightClientBehaviorRendererTest.java (added)
+++ myfaces/tomahawk/trunk/core20/src/test/java/org/apache/myfaces/custom/layout/HtmlLayoutNavRightClientBehaviorRendererTest.java Fri Jul 30 00:33:23 2010
@@ -0,0 +1,74 @@
+/*
+ * 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.
+ */
+package org.apache.myfaces.custom.layout;
+
+import javax.faces.component.UIComponent;
+
+import org.apache.myfaces.component.behavior.AbstractClientBehaviorTestCase;
+import org.apache.myfaces.component.behavior.HtmlClientEventAttributesUtil;
+import org.apache.myfaces.component.behavior.HtmlRenderedClientEventAttr;
+import org.apache.myfaces.component.html.ext.HtmlPanelGrid;
+import org.junit.Ignore;
+import org.junit.Test;
+
+/**
+ * @author Leonardo Uribe (latest modification by $Author: jankeesvanandel $)
+ * @version $Revision: 799929 $ $Date: 2009-08-01 16:29:33 -0500 (sáb, 01 ago 2009) $
+ */
+public class HtmlLayoutNavRightClientBehaviorRendererTest extends AbstractClientBehaviorTestCase
+{
+    private HtmlRenderedClientEventAttr[] attrs = null;
+    
+    @Override
+    public void setUp() throws Exception
+    {
+        super.setUp();
+        attrs = HtmlClientEventAttributesUtil.generateClientBehaviorEventAttrs();
+    }
+
+    @Override
+    public void tearDown() throws Exception
+    {
+        super.tearDown();
+        attrs = null;
+    }
+
+
+    @Override
+    protected UIComponent createComponentToTest()
+    {
+        HtmlPanelLayout panelLayout = new HtmlPanelLayout();
+        panelLayout.setLayout("navigationRight");
+        return panelLayout;
+    }
+
+    @Override
+    protected HtmlRenderedClientEventAttr[] getClientBehaviorHtmlRenderedAttributes()
+    {
+        return attrs;
+    }
+    
+    @Ignore
+    @Test
+    @Override
+    public void testClientBehaviorHolderRendersName() 
+    {
+        super.testClientBehaviorHolderRendersName();
+    }
+}

Added: myfaces/tomahawk/trunk/core20/src/test/java/org/apache/myfaces/custom/layout/HtmlLayoutUpsideDownClientBehaviorRendererTest.java
URL: http://svn.apache.org/viewvc/myfaces/tomahawk/trunk/core20/src/test/java/org/apache/myfaces/custom/layout/HtmlLayoutUpsideDownClientBehaviorRendererTest.java?rev=980615&view=auto
==============================================================================
--- myfaces/tomahawk/trunk/core20/src/test/java/org/apache/myfaces/custom/layout/HtmlLayoutUpsideDownClientBehaviorRendererTest.java (added)
+++ myfaces/tomahawk/trunk/core20/src/test/java/org/apache/myfaces/custom/layout/HtmlLayoutUpsideDownClientBehaviorRendererTest.java Fri Jul 30 00:33:23 2010
@@ -0,0 +1,74 @@
+/*
+ * 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.
+ */
+package org.apache.myfaces.custom.layout;
+
+import javax.faces.component.UIComponent;
+
+import org.apache.myfaces.component.behavior.AbstractClientBehaviorTestCase;
+import org.apache.myfaces.component.behavior.HtmlClientEventAttributesUtil;
+import org.apache.myfaces.component.behavior.HtmlRenderedClientEventAttr;
+import org.apache.myfaces.component.html.ext.HtmlPanelGrid;
+import org.junit.Ignore;
+import org.junit.Test;
+
+/**
+ * @author Leonardo Uribe (latest modification by $Author: jankeesvanandel $)
+ * @version $Revision: 799929 $ $Date: 2009-08-01 16:29:33 -0500 (sáb, 01 ago 2009) $
+ */
+public class HtmlLayoutUpsideDownClientBehaviorRendererTest extends AbstractClientBehaviorTestCase
+{
+    private HtmlRenderedClientEventAttr[] attrs = null;
+    
+    @Override
+    public void setUp() throws Exception
+    {
+        super.setUp();
+        attrs = HtmlClientEventAttributesUtil.generateClientBehaviorEventAttrs();
+    }
+
+    @Override
+    public void tearDown() throws Exception
+    {
+        super.tearDown();
+        attrs = null;
+    }
+
+
+    @Override
+    protected UIComponent createComponentToTest()
+    {
+        HtmlPanelLayout panelLayout = new HtmlPanelLayout();
+        panelLayout.setLayout("upsideDown");
+        return panelLayout;
+    }
+
+    @Override
+    protected HtmlRenderedClientEventAttr[] getClientBehaviorHtmlRenderedAttributes()
+    {
+        return attrs;
+    }
+    
+    @Ignore
+    @Test
+    @Override
+    public void testClientBehaviorHolderRendersName() 
+    {
+        super.testClientBehaviorHolderRendersName();
+    }
+}

Added: myfaces/tomahawk/trunk/core20/src/test/java/org/apache/myfaces/custom/navigation/HtmlNavigationClientBehaviorTest.java
URL: http://svn.apache.org/viewvc/myfaces/tomahawk/trunk/core20/src/test/java/org/apache/myfaces/custom/navigation/HtmlNavigationClientBehaviorTest.java?rev=980615&view=auto
==============================================================================
--- myfaces/tomahawk/trunk/core20/src/test/java/org/apache/myfaces/custom/navigation/HtmlNavigationClientBehaviorTest.java (added)
+++ myfaces/tomahawk/trunk/core20/src/test/java/org/apache/myfaces/custom/navigation/HtmlNavigationClientBehaviorTest.java Fri Jul 30 00:33:23 2010
@@ -0,0 +1,74 @@
+/*
+ * 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.
+ */
+package org.apache.myfaces.custom.navigation;
+
+import javax.faces.component.UIComponent;
+
+import org.apache.myfaces.component.behavior.AbstractClientBehaviorTestCase;
+import org.apache.myfaces.component.behavior.HtmlClientEventAttributesUtil;
+import org.apache.myfaces.component.behavior.HtmlRenderedClientEventAttr;
+import org.apache.myfaces.custom.navmenu.UINavigationMenuItem;
+import org.junit.Ignore;
+import org.junit.Test;
+
+
+public class HtmlNavigationClientBehaviorTest extends AbstractClientBehaviorTestCase
+{
+    private HtmlRenderedClientEventAttr[] attrs = null;
+    
+    @Override
+    public void setUp() throws Exception
+    {
+        super.setUp();
+        attrs = HtmlClientEventAttributesUtil.generateClientBehaviorEventAttrs();
+    }
+
+    @Override
+    public void tearDown() throws Exception
+    {
+        super.tearDown();
+        attrs = null;
+    }
+
+    @Override
+    protected UIComponent createComponentToTest()
+    {
+        HtmlPanelNavigation navigation = new HtmlPanelNavigation();
+        UINavigationMenuItem menuItem = new UINavigationMenuItem();
+        navigation.getChildren().add(menuItem);
+        return navigation;
+    }
+
+    @Override
+    protected HtmlRenderedClientEventAttr[] getClientBehaviorHtmlRenderedAttributes()
+    {
+        return attrs;
+    }
+    
+    /**
+     * div tag does not have name attribute
+     */
+    @Test
+    @Ignore
+    @Override
+    public void testClientBehaviorHolderRendersName()
+    {
+        super.testClientBehaviorHolderRendersName();
+    }
+}

Added: myfaces/tomahawk/trunk/core20/src/test/java/org/apache/myfaces/custom/navmenu/htmlnavmenu/HtmlNavigationMenuClientBehaviorTest.java
URL: http://svn.apache.org/viewvc/myfaces/tomahawk/trunk/core20/src/test/java/org/apache/myfaces/custom/navmenu/htmlnavmenu/HtmlNavigationMenuClientBehaviorTest.java?rev=980615&view=auto
==============================================================================
--- myfaces/tomahawk/trunk/core20/src/test/java/org/apache/myfaces/custom/navmenu/htmlnavmenu/HtmlNavigationMenuClientBehaviorTest.java (added)
+++ myfaces/tomahawk/trunk/core20/src/test/java/org/apache/myfaces/custom/navmenu/htmlnavmenu/HtmlNavigationMenuClientBehaviorTest.java Fri Jul 30 00:33:23 2010
@@ -0,0 +1,73 @@
+/*
+ * 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.
+ */
+package org.apache.myfaces.custom.navmenu.htmlnavmenu;
+
+import javax.faces.component.UIComponent;
+
+import org.apache.myfaces.component.behavior.AbstractClientBehaviorTestCase;
+import org.apache.myfaces.component.behavior.HtmlClientEventAttributesUtil;
+import org.apache.myfaces.component.behavior.HtmlRenderedClientEventAttr;
+import org.junit.Ignore;
+import org.junit.Test;
+
+
+public class HtmlNavigationMenuClientBehaviorTest extends AbstractClientBehaviorTestCase
+{
+    private HtmlRenderedClientEventAttr[] attrs = null;
+    
+    @Override
+    public void setUp() throws Exception
+    {
+        super.setUp();
+        attrs = HtmlClientEventAttributesUtil.generateClientBehaviorEventAttrs();
+    }
+
+    @Override
+    public void tearDown() throws Exception
+    {
+        super.tearDown();
+        attrs = null;
+    }
+
+    @Override
+    protected UIComponent createComponentToTest()
+    {
+        HtmlPanelNavigationMenu navigation = new HtmlPanelNavigationMenu();
+        HtmlCommandNavigationItem menuItem = new HtmlCommandNavigationItem();
+        navigation.getChildren().add(menuItem);
+        return navigation;
+    }
+
+    @Override
+    protected HtmlRenderedClientEventAttr[] getClientBehaviorHtmlRenderedAttributes()
+    {
+        return attrs;
+    }
+    
+    /**
+     * div tag does not have name attribute
+     */
+    @Test
+    @Ignore
+    @Override
+    public void testClientBehaviorHolderRendersName()
+    {
+        super.testClientBehaviorHolderRendersName();
+    }
+}

Added: myfaces/tomahawk/trunk/core20/src/test/java/org/apache/myfaces/custom/navmenu/htmlnavmenu/HtmlNavigationMenuRendererTest.java
URL: http://svn.apache.org/viewvc/myfaces/tomahawk/trunk/core20/src/test/java/org/apache/myfaces/custom/navmenu/htmlnavmenu/HtmlNavigationMenuRendererTest.java?rev=980615&view=auto
==============================================================================
--- myfaces/tomahawk/trunk/core20/src/test/java/org/apache/myfaces/custom/navmenu/htmlnavmenu/HtmlNavigationMenuRendererTest.java (added)
+++ myfaces/tomahawk/trunk/core20/src/test/java/org/apache/myfaces/custom/navmenu/htmlnavmenu/HtmlNavigationMenuRendererTest.java Fri Jul 30 00:33:23 2010
@@ -0,0 +1,83 @@
+/*
+ * 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.
+ */
+package org.apache.myfaces.custom.navmenu.htmlnavmenu;
+
+import junit.framework.Test;
+import junit.framework.TestSuite;
+
+import org.apache.myfaces.custom.navmenu.UINavigationMenuItem;
+import org.apache.myfaces.test.AbstractTomahawkViewControllerTestCase;
+import org.apache.myfaces.test.mock.MockResponseWriter;
+import org.apache.myfaces.test.utils.HtmlCheckAttributesUtil;
+import org.apache.myfaces.test.utils.HtmlRenderedAttr;
+
+public class HtmlNavigationMenuRendererTest extends AbstractTomahawkViewControllerTestCase
+{
+    private HtmlPanelNavigationMenu navigation;
+    
+    
+    public HtmlNavigationMenuRendererTest(String name)
+    {
+        super(name);
+    }
+
+    public static Test suite() {
+        return new TestSuite(HtmlNavigationMenuRendererTest.class);
+    }
+    
+    public void setUp() throws Exception
+    {
+        super.setUp();
+        navigation = new HtmlPanelNavigationMenu();
+        HtmlCommandNavigationItem menuItem = new HtmlCommandNavigationItem();
+        navigation.getChildren().add(menuItem);
+    }
+    
+    public void tearDown() throws Exception 
+    {
+        super.tearDown();
+        navigation = null;
+    }
+    
+    public void testHtmlPropertyPassTru() throws Exception
+    {
+        HtmlRenderedAttr[] attrs = HtmlCheckAttributesUtil.generateBasicReadOnlyAttrs();
+        
+        MockResponseWriter writer = (MockResponseWriter)facesContext.getResponseWriter();
+        HtmlCheckAttributesUtil.checkRenderedAttributes(
+                navigation, facesContext, writer, attrs);
+        if(HtmlCheckAttributesUtil.hasFailedAttrRender(attrs)) 
+        {
+            fail(HtmlCheckAttributesUtil.constructErrorMessage(attrs, writer.getWriter().toString()));
+        }
+    }
+    
+    public void testHtmlPropertyPassTruNotRendered() throws Exception
+    {
+        HtmlRenderedAttr[] attrs = HtmlCheckAttributesUtil.generateAttrsNotRenderedForReadOnly();
+        
+        MockResponseWriter writer = (MockResponseWriter)facesContext.getResponseWriter();
+        HtmlCheckAttributesUtil.checkRenderedAttributes(
+                navigation, facesContext, writer, attrs);
+        if(HtmlCheckAttributesUtil.hasFailedAttrRender(attrs)) 
+        {
+            fail(HtmlCheckAttributesUtil.constructErrorMessage(attrs, writer.getWriter().toString()));
+        }
+    }
+}

Added: myfaces/tomahawk/trunk/core20/src/test/java/org/apache/myfaces/custom/newspaper/HtmlNewspaperTableClientBehaviorRendererTest.java
URL: http://svn.apache.org/viewvc/myfaces/tomahawk/trunk/core20/src/test/java/org/apache/myfaces/custom/newspaper/HtmlNewspaperTableClientBehaviorRendererTest.java?rev=980615&view=auto
==============================================================================
--- myfaces/tomahawk/trunk/core20/src/test/java/org/apache/myfaces/custom/newspaper/HtmlNewspaperTableClientBehaviorRendererTest.java (added)
+++ myfaces/tomahawk/trunk/core20/src/test/java/org/apache/myfaces/custom/newspaper/HtmlNewspaperTableClientBehaviorRendererTest.java Fri Jul 30 00:33:23 2010
@@ -0,0 +1,72 @@
+/*
+ * 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.
+ */
+package org.apache.myfaces.custom.newspaper;
+
+import javax.faces.component.UIComponent;
+
+import org.apache.myfaces.component.behavior.AbstractClientBehaviorTestCase;
+import org.apache.myfaces.component.behavior.HtmlClientEventAttributesUtil;
+import org.apache.myfaces.component.behavior.HtmlRenderedClientEventAttr;
+import org.apache.myfaces.component.html.ext.HtmlDataTable;
+import org.junit.Ignore;
+import org.junit.Test;
+
+/**
+ * @author Leonardo Uribe (latest modification by $Author: jankeesvanandel $)
+ * @version $Revision: 799929 $ $Date: 2009-08-01 16:29:33 -0500 (sáb, 01 ago 2009) $
+ */
+public class HtmlNewspaperTableClientBehaviorRendererTest extends AbstractClientBehaviorTestCase
+{
+    private HtmlRenderedClientEventAttr[] attrs = null;
+    
+    @Override
+    public void setUp() throws Exception
+    {
+        super.setUp();
+        attrs = HtmlClientEventAttributesUtil.generateClientBehaviorEventAttrs();
+    }
+
+    @Override
+    public void tearDown() throws Exception
+    {
+        super.tearDown();
+        attrs = null;
+    }
+
+
+    @Override
+    protected UIComponent createComponentToTest()
+    {
+        return new HtmlNewspaperTable();
+    }
+
+    @Override
+    protected HtmlRenderedClientEventAttr[] getClientBehaviorHtmlRenderedAttributes()
+    {
+        return attrs;
+    }
+    
+    @Test
+    @Ignore
+    @Override
+    public void testClientBehaviorHolderRendersName()
+    {
+        super.testClientBehaviorHolderRendersName();
+    }
+}

Added: myfaces/tomahawk/trunk/core20/src/test/java/org/apache/myfaces/custom/picklist/HtmlPicklistClientBehaviorRendererTest.java
URL: http://svn.apache.org/viewvc/myfaces/tomahawk/trunk/core20/src/test/java/org/apache/myfaces/custom/picklist/HtmlPicklistClientBehaviorRendererTest.java?rev=980615&view=auto
==============================================================================
--- myfaces/tomahawk/trunk/core20/src/test/java/org/apache/myfaces/custom/picklist/HtmlPicklistClientBehaviorRendererTest.java (added)
+++ myfaces/tomahawk/trunk/core20/src/test/java/org/apache/myfaces/custom/picklist/HtmlPicklistClientBehaviorRendererTest.java Fri Jul 30 00:33:23 2010
@@ -0,0 +1,76 @@
+/*
+ * 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.
+ */
+package org.apache.myfaces.custom.picklist;
+
+import javax.faces.component.UIComponent;
+import javax.faces.component.UISelectItem;
+
+import org.apache.myfaces.component.behavior.AbstractClientBehaviorTestCase;
+import org.apache.myfaces.component.behavior.HtmlClientEventAttributesUtil;
+import org.apache.myfaces.component.behavior.HtmlRenderedClientEventAttr;
+import org.junit.Ignore;
+import org.junit.Test;
+
+/**
+ * @author Leonardo Uribe (latest modification by $Author: jankeesvanandel $)
+ * @version $Revision: 799929 $ $Date: 2009-08-01 16:29:33 -0500 (sáb, 01 ago 2009) $
+ */
+public class HtmlPicklistClientBehaviorRendererTest extends AbstractClientBehaviorTestCase
+{
+    private HtmlRenderedClientEventAttr[] attrs = null;
+    
+    @Override
+    public void setUp() throws Exception
+    {
+        super.setUp();
+        attrs = HtmlClientEventAttributesUtil.generateClientBehaviorInputEventAttrs();
+    }
+
+    @Override
+    public void tearDown() throws Exception
+    {
+        super.tearDown();
+        attrs = null;
+    }
+
+
+    @Override
+    protected UIComponent createComponentToTest()
+    {
+        UIComponent component = new HtmlSelectManyPicklist();
+        UISelectItem item = new UISelectItem();
+        item.setItemValue("value1");
+        component.getChildren().add(item);
+        return component;
+    }
+
+    @Override
+    protected HtmlRenderedClientEventAttr[] getClientBehaviorHtmlRenderedAttributes()
+    {
+        return attrs;
+    }
+
+    @Test
+    @Ignore
+    @Override
+    public void testClientBehaviorHolderRendersName()
+    {
+        super.testClientBehaviorHolderRendersName();
+    }
+}

Added: myfaces/tomahawk/trunk/core20/src/test/java/org/apache/myfaces/custom/selectOneCountry/SelectOneCountryClientBehaviorRendererTest.java
URL: http://svn.apache.org/viewvc/myfaces/tomahawk/trunk/core20/src/test/java/org/apache/myfaces/custom/selectOneCountry/SelectOneCountryClientBehaviorRendererTest.java?rev=980615&view=auto
==============================================================================
--- myfaces/tomahawk/trunk/core20/src/test/java/org/apache/myfaces/custom/selectOneCountry/SelectOneCountryClientBehaviorRendererTest.java (added)
+++ myfaces/tomahawk/trunk/core20/src/test/java/org/apache/myfaces/custom/selectOneCountry/SelectOneCountryClientBehaviorRendererTest.java Fri Jul 30 00:33:23 2010
@@ -0,0 +1,63 @@
+/*
+ * 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.
+ */
+package org.apache.myfaces.custom.selectOneCountry;
+
+import javax.faces.component.UIComponent;
+import javax.faces.component.UISelectItem;
+
+import org.apache.myfaces.component.behavior.AbstractClientBehaviorTestCase;
+import org.apache.myfaces.component.behavior.HtmlClientEventAttributesUtil;
+import org.apache.myfaces.component.behavior.HtmlRenderedClientEventAttr;
+import org.apache.myfaces.component.html.ext.HtmlSelectOneMenu;
+
+/**
+ * @author Leonardo Uribe (latest modification by $Author: jankeesvanandel $)
+ * @version $Revision: 799929 $ $Date: 2009-08-01 16:29:33 -0500 (sáb, 01 ago 2009) $
+ */
+public class SelectOneCountryClientBehaviorRendererTest extends AbstractClientBehaviorTestCase
+{
+    private HtmlRenderedClientEventAttr[] attrs = null;
+    
+    @Override
+    public void setUp() throws Exception
+    {
+        super.setUp();
+        attrs = HtmlClientEventAttributesUtil.generateClientBehaviorInputEventAttrs();
+    }
+
+    @Override
+    public void tearDown() throws Exception
+    {
+        super.tearDown();
+        attrs = null;
+    }
+
+
+    @Override
+    protected UIComponent createComponentToTest()
+    {
+        return new SelectOneCountry();
+    }
+
+    @Override
+    protected HtmlRenderedClientEventAttr[] getClientBehaviorHtmlRenderedAttributes()
+    {
+        return attrs;
+    }
+}

Added: myfaces/tomahawk/trunk/core20/src/test/java/org/apache/myfaces/custom/selectOneLanguage/SelectOneLanguageClientBehaviorRendererTest.java
URL: http://svn.apache.org/viewvc/myfaces/tomahawk/trunk/core20/src/test/java/org/apache/myfaces/custom/selectOneLanguage/SelectOneLanguageClientBehaviorRendererTest.java?rev=980615&view=auto
==============================================================================
--- myfaces/tomahawk/trunk/core20/src/test/java/org/apache/myfaces/custom/selectOneLanguage/SelectOneLanguageClientBehaviorRendererTest.java (added)
+++ myfaces/tomahawk/trunk/core20/src/test/java/org/apache/myfaces/custom/selectOneLanguage/SelectOneLanguageClientBehaviorRendererTest.java Fri Jul 30 00:33:23 2010
@@ -0,0 +1,63 @@
+/*
+ * 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.
+ */
+package org.apache.myfaces.custom.selectOneLanguage;
+
+import javax.faces.component.UIComponent;
+import javax.faces.component.UISelectItem;
+
+import org.apache.myfaces.component.behavior.AbstractClientBehaviorTestCase;
+import org.apache.myfaces.component.behavior.HtmlClientEventAttributesUtil;
+import org.apache.myfaces.component.behavior.HtmlRenderedClientEventAttr;
+import org.apache.myfaces.component.html.ext.HtmlSelectOneMenu;
+
+/**
+ * @author Leonardo Uribe (latest modification by $Author: jankeesvanandel $)
+ * @version $Revision: 799929 $ $Date: 2009-08-01 16:29:33 -0500 (sáb, 01 ago 2009) $
+ */
+public class SelectOneLanguageClientBehaviorRendererTest extends AbstractClientBehaviorTestCase
+{
+    private HtmlRenderedClientEventAttr[] attrs = null;
+    
+    @Override
+    public void setUp() throws Exception
+    {
+        super.setUp();
+        attrs = HtmlClientEventAttributesUtil.generateClientBehaviorInputEventAttrs();
+    }
+
+    @Override
+    public void tearDown() throws Exception
+    {
+        super.tearDown();
+        attrs = null;
+    }
+
+
+    @Override
+    protected UIComponent createComponentToTest()
+    {
+        return new SelectOneLanguage();
+    }
+
+    @Override
+    protected HtmlRenderedClientEventAttr[] getClientBehaviorHtmlRenderedAttributes()
+    {
+        return attrs;
+    }
+}

Added: myfaces/tomahawk/trunk/core20/src/test/java/org/apache/myfaces/custom/selectOneRow/SelectOneRowClientBehaviorRendererTest.java
URL: http://svn.apache.org/viewvc/myfaces/tomahawk/trunk/core20/src/test/java/org/apache/myfaces/custom/selectOneRow/SelectOneRowClientBehaviorRendererTest.java?rev=980615&view=auto
==============================================================================
--- myfaces/tomahawk/trunk/core20/src/test/java/org/apache/myfaces/custom/selectOneRow/SelectOneRowClientBehaviorRendererTest.java (added)
+++ myfaces/tomahawk/trunk/core20/src/test/java/org/apache/myfaces/custom/selectOneRow/SelectOneRowClientBehaviorRendererTest.java Fri Jul 30 00:33:23 2010
@@ -0,0 +1,116 @@
+/*
+ * 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.
+ */
+package org.apache.myfaces.custom.selectOneRow;
+
+import javax.faces.component.UIComponent;
+import javax.faces.component.UISelectItem;
+import javax.faces.component.behavior.AjaxBehavior;
+import javax.faces.component.behavior.ClientBehaviorHolder;
+
+import org.apache.myfaces.component.behavior.AbstractClientBehaviorTestCase;
+import org.apache.myfaces.component.behavior.HtmlClientEventAttributesUtil;
+import org.apache.myfaces.component.behavior.HtmlRenderedClientEventAttr;
+import org.apache.myfaces.component.html.ext.HtmlSelectOneRadio;
+import org.junit.Assert;
+
+/**
+ * @author Leonardo Uribe (latest modification by $Author: jankeesvanandel $)
+ * @version $Revision: 799929 $ $Date: 2009-08-01 16:29:33 -0500 (sáb, 01 ago 2009) $
+ */
+public class SelectOneRowClientBehaviorRendererTest extends AbstractClientBehaviorTestCase
+{
+    private HtmlRenderedClientEventAttr[] attrs = null;
+    
+    @Override
+    public void setUp() throws Exception
+    {
+        super.setUp();
+        attrs = HtmlClientEventAttributesUtil.generateClientBehaviorInputEventAttrs();
+    }
+
+    @Override
+    public void tearDown() throws Exception
+    {
+        super.tearDown();
+        attrs = null;
+    }
+
+
+    @Override
+    protected UIComponent createComponentToTest()
+    {
+        SelectOneRow selectOneRow = new SelectOneRow();   
+        selectOneRow.setGroupName("groupName");
+        return selectOneRow;
+    }
+
+    @Override
+    protected HtmlRenderedClientEventAttr[] getClientBehaviorHtmlRenderedAttributes()
+    {
+        return attrs;
+    }
+    
+    @Override
+    public void testClientBehaviorHolderRendersId() 
+    {
+        HtmlRenderedClientEventAttr[] attrs = getClientBehaviorHtmlRenderedAttributes();
+        
+        for (int i = 0; i < attrs.length; i++)
+        {
+            UIComponent component = createComponentToTest();
+            ClientBehaviorHolder clientBehaviorHolder = (ClientBehaviorHolder) component;
+            clientBehaviorHolder.addClientBehavior(attrs[i].getClientEvent(), new AjaxBehavior());
+            try 
+            {
+                component.encodeAll(facesContext);
+                String output = outputWriter.toString();
+                Assert.assertTrue(output.matches(".+ id=\".+\".+"));
+                outputWriter.reset();
+            }
+            catch (Exception e)
+            {
+                Assert.fail(e.getMessage());
+            }
+        }
+    }
+    
+    @Override
+    public void testClientBehaviorHolderRendersName() 
+    {
+        HtmlRenderedClientEventAttr[] attrs = getClientBehaviorHtmlRenderedAttributes();
+        
+        for (int i = 0; i < attrs.length; i++)
+        {
+            UIComponent component = createComponentToTest();
+            ClientBehaviorHolder clientBehaviorHolder = (ClientBehaviorHolder) component;
+            clientBehaviorHolder.addClientBehavior(attrs[i].getClientEvent(), new AjaxBehavior());
+            try 
+            {
+                component.encodeAll(facesContext);
+                String output = outputWriter.toString();
+                Assert.assertTrue(output.matches(".+ name=\".+\".+"));
+                outputWriter.reset();
+            }
+            catch (Exception e)
+            {
+                Assert.fail(e.getMessage());
+            }
+        }
+    }
+}