1 18 package org.apache.struts.taglib.html; 19 20 import java.util.Locale ; 21 22 import javax.servlet.jsp.PageContext ; 23 import junit.framework.Test; 24 import junit.framework.TestSuite; 25 26 import org.apache.cactus.JspTestCase; 27 import org.apache.struts.Globals; 28 import org.apache.struts.taglib.SimpleBeanForTesting; 29 30 53 public class TestMultiboxTag1 extends JspTestCase { 54 55 60 public TestMultiboxTag1(String theName) { 61 super(theName); 62 } 63 64 69 public static void main(String [] theArgs) { 70 junit.awtui.TestRunner.main(new String [] {TestMultiboxTag1.class.getName()}); 71 } 72 73 77 public static Test suite() { 78 return new TestSuite(TestMultiboxTag1.class); 80 } 81 82 private void runMyTest(String whichTest, String locale) throws Exception { 83 pageContext.setAttribute(Globals.LOCALE_KEY, 84 new Locale (locale, locale), 85 PageContext.SESSION_SCOPE); 86 87 String [] s = new String [7]; 88 for(int i = 1; i < 7; i++){ 89 s[i] = "value" + i; 90 } 91 SimpleBeanForTesting sbft = new SimpleBeanForTesting(s); 92 93 pageContext.setAttribute(Constants.BEAN_KEY, sbft, PageContext.REQUEST_SCOPE); 94 request.setAttribute("runTest", whichTest); 95 pageContext.forward("/test/org/apache/struts/taglib/html/TestMultiboxTag1.jsp"); 96 } 97 98 101 public void testMultiboxPropertyTrue() throws Exception { 102 runMyTest("testMultiboxPropertyTrue", ""); 103 } 104 public void testMultiboxPropertyTrueAccesskey() throws Exception { 105 runMyTest("testMultiboxPropertyTrueAccesskey", ""); 106 } 107 public void testMultiboxPropertyTrueAlt() throws Exception { 108 runMyTest("testMultiboxPropertyTrueAlt", ""); 109 } 110 public void testMultiboxPropertyTrueAltKey1() throws Exception { 111 runMyTest("testMultiboxPropertyTrueAltKey1", ""); 112 } 113 public void testMultiboxPropertyTrueAltKey2() throws Exception { 114 runMyTest("testMultiboxPropertyTrueAltKey2", ""); 115 } 116 public void testMultiboxPropertyTrueAltKey3() throws Exception { 117 runMyTest("testMultiboxPropertyTrueAltKey3", ""); 118 } 119 public void testMultiboxPropertyTrueAltKey_fr1() throws Exception { 120 runMyTest("testMultiboxPropertyTrueAltKey1_fr", "fr"); 121 } 122 public void testMultiboxPropertyTrueAltKey_fr2() throws Exception { 123 runMyTest("testMultiboxPropertyTrueAltKey2_fr", "fr"); 124 } 125 public void testMultiboxPropertyTrueDisabled_True() throws Exception { 126 runMyTest("testMultiboxPropertyTrueDisabled_True", ""); 127 } 128 public void testMultiboxPropertyTrueDisabled_False1() throws Exception { 129 runMyTest("testMultiboxPropertyTrueDisabled_False1", ""); 130 } 131 public void testMultiboxPropertyTrueDisabled_False2() throws Exception { 132 runMyTest("testMultiboxPropertyTrueDisabled_False2", ""); 133 } 134 public void testMultiboxPropertyTrueOnblur() throws Exception { 135 runMyTest("testMultiboxPropertyTrueOnblur", ""); 136 } 137 138 public void testMultiboxPropertyTrueOnchange() throws Exception { 139 runMyTest("testMultiboxPropertyTrueOnchange", ""); 140 } 141 142 public void testMultiboxPropertyTrueOnclick() throws Exception { 143 runMyTest("testMultiboxPropertyTrueOnclick", ""); 144 } 145 146 public void testMultiboxPropertyTrueOndblclick() throws Exception { 147 runMyTest("testMultiboxPropertyTrueOndblclick", ""); 148 } 149 150 public void testMultiboxPropertyTrueOnfocus() throws Exception { 151 runMyTest("testMultiboxPropertyTrueOnfocus", ""); 152 } 153 154 public void testMultiboxPropertyTrueOnkeydown() throws Exception { 155 runMyTest("testMultiboxPropertyTrueOnkeydown", ""); 156 } 157 158 public void testMultiboxPropertyTrueOnkeypress() throws Exception { 159 runMyTest("testMultiboxPropertyTrueOnkeypress", ""); 160 } 161 162 public void testMultiboxPropertyTrueOnkeyup() throws Exception { 163 runMyTest("testMultiboxPropertyTrueOnkeyup", ""); 164 } 165 166 public void testMultiboxPropertyTrueOnmousedown() throws Exception { 167 runMyTest("testMultiboxPropertyTrueOnmousedown", ""); 168 } 169 170 public void testMultiboxPropertyTrueOnmousemove() throws Exception { 171 runMyTest("testMultiboxPropertyTrueOnmousemove", ""); 172 } 173 174 public void testMultiboxPropertyTrueOnmouseout() throws Exception { 175 runMyTest("testMultiboxPropertyTrueOnmouseout", ""); 176 } 177 178 public void testMultiboxPropertyTrueOnmouseover() throws Exception { 179 runMyTest("testMultiboxPropertyTrueOnmouseover", ""); 180 } 181 182 public void testMultiboxPropertyTrueOnmouseup() throws Exception { 183 runMyTest("testMultiboxPropertyTrueOnmouseup", ""); 184 } 185 186 } 187 | Popular Tags |