1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19 package org.apache.myfaces.trinidad.component.core.layout;
20
21 import junit.framework.Test;
22 import junit.framework.TestSuite;
23
24 import org.apache.myfaces.trinidad.component.UIXPanel;
25
26
27
28
29
30 public class CorePanelListTest extends UIXPanelTestCase
31 {
32
33
34
35
36
37 public CorePanelListTest(
38 String testName)
39 {
40 super(testName);
41 }
42
43 @Override
44 protected void setUp() throws Exception
45 {
46 super.setUp();
47 }
48
49 @Override
50 protected void tearDown() throws Exception
51 {
52 super.tearDown();
53 }
54
55 public static Test suite()
56 {
57 return new TestSuite(CorePanelListTest.class);
58 }
59
60
61
62
63 public void testInitialAttributeValues()
64 {
65 CorePanelList component = new CorePanelList();
66 assertTrue(component.isRendered());
67 assertEquals(Integer.MAX_VALUE, component.getRows());
68 assertEquals(3, component.getMaxColumns());
69 }
70
71
72
73
74
75
76 public void testAttributeTransparency()
77 {
78 CorePanelList component = new CorePanelList();
79
80 doTestAttributeTransparency(component, "rendered",
81 Boolean.TRUE, Boolean.FALSE);
82 doTestAttributeTransparency(component, "rows",
83 new Integer(1), new Integer(2));
84
85 doTestAttributeTransparency(component, "maxColumns",
86 new Integer(1), new Integer(2));
87 }
88
89 @Override
90 protected UIXPanel createTestComponent()
91 {
92 return new CorePanelList();
93 }
94 }