1 28 29 package com.idaremedia.antx.tests; 30 31 import junit.framework.TestSuite; 32 33 import com.idaremedia.antx.ut.HTC; 34 import com.idaremedia.antx.ut.HTCUtils; 35 36 47 48 public class AssertLoggedTaskTest extends HTC 49 { 50 51 public static final String TEST_CATEGORY="CLASS"; 52 53 54 57 public AssertLoggedTaskTest(String methodName) 58 { 59 super("AssertLoggedTask::",methodName); 60 } 61 62 63 66 public static TestSuite suite() 67 { 68 return new TestSuite(AssertLoggedTaskTest.class); 69 } 70 71 72 75 public static TestSuite baseline() 76 { 77 return suite(); 78 } 79 80 81 84 public static void main(String [] argv) 85 { 86 HTCUtils.quickCheck(suite()); 87 } 88 89 90 94 protected void setUp() throws Exception 95 { 96 super.setUp(); 97 configureProjectFromResource("assertlog.xml"); 98 } 99 100 104 public void checkBaseline() 105 { 106 } 108 109 public void testBaseline() 110 { 111 checkBaseline(); 112 } 113 114 public void testEmptyLogRecorderWorks() 115 { 116 runTarget("testEmptyLogsRecorder"); 117 } 118 119 public void testBrokenMixtureOfValueAndNestedStrings() 120 { 121 runExpecting("testBrokenMixtureOfValueAndNestedStrings", 122 "Can't have mixture of 'value' and 'string' elements"); 123 } 124 125 public void testNeedAtLeastValueOrNestedString() 126 { 127 runExpecting("testNeedAtLeastValueOrNestedString", 128 "Need value or nested 'string'"); 129 } 130 131 public void testFalseCheckThrowsException() 132 { 133 runExpecting("testFalseTest_1","String 'ickyblorf' not in log"); 134 runExpecting("testFalseTest_2","String '(fubar)))' not in log"); 135 runExpecting("testFalseTest_3","String '((fubar))' not in important logs"); 136 runExpecting("testFalseTest_4","Log isn't rewound to look for each string"); 137 } 138 139 public void testCaptureDefaultLevels() 140 { 141 runTarget("testCaptureDefaultLevels"); 142 } 143 144 145 public void testCaptureDefaultLevelsStdio_AntX03() 146 { 147 runTarget("testCaptureDefaultLevelsStdio_AntX03"); 148 } 149 150 public void testDifferentiateImportantUnimportant() 151 { 152 runTarget("testDifferentiateImportantUnimportant"); 153 } 154 155 public void testClearingLogs() 156 { 157 runTarget("testClearingLogs"); 158 } 159 160 public void testPassOrderedNestedItems() 161 { 162 runTarget("testFindOrderedItems"); 163 } 164 165 public void testNestedCapturedLogs() 166 { 167 runTarget("testNestedCaptureLogs"); 168 } 169 170 171 public void testCopyingCapturedLogs_AntX03() 172 { 173 runTarget("testCopyingCapturedLogs"); 174 } 175 176 177 public void testMatchRegularExpressions_AntX03() 178 { 179 runTarget("testMatchingREs"); 180 } 181 182 183 public void testCopyToFileByURL_AntX05() 184 { 185 runTarget("testCopyToFileByURL_AntX05"); 186 } 187 } 188 189 190 191 | Popular Tags |