1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21 package org.apache.struts2.views.jsp.ui;
22
23 import org.apache.struts2.views.jsp.AbstractUITagTest;
24
25
26 /***
27 */
28 public class DateTimePickerTagTest extends AbstractUITagTest {
29
30
31 public void testGenericSimple() throws Exception {
32 AbstractRemoteCallUITag tag = new DivTag();
33 verifyGenericProperties(tag, "simple", new String[]{"value","tabindex","disabled"});
34 }
35
36 public void testGenericXhtml() throws Exception {
37 AbstractRemoteCallUITag tag = new DivTag();
38 verifyGenericProperties(tag, "xhtml", new String[]{"value","tabindex","disabled"});
39 }
40
41 public void testGenericAjax() throws Exception {
42 AbstractRemoteCallUITag tag = new DivTag();
43 verifyGenericProperties(tag, "ajax", new String[]{"value","tabindex","disabled"});
44 }
45
46 public void testSimple() throws Exception {
47 DateTimePickerTag tag = new DateTimePickerTag();
48 tag.setPageContext(pageContext);
49
50 tag.setId("id");
51 tag.setTheme("ajax");
52
53 tag.setAdjustWeeks("true");
54 tag.setDayWidth("b");
55 tag.setDisplayWeeks("true");
56 tag.setEndDate("d");
57 tag.setStartDate("e");
58 tag.setStaticDisplay("false");
59 tag.setWeekStartsOn("g");
60 tag.setName("h");
61 tag.setLanguage("i");
62 tag.doStartTag();
63 tag.doEndTag();
64
65 verify(DateTimePickerTagTest.class.getResource("DateTimePickerTagTest-1.txt"));
66 }
67
68 }