1 26 27 package net.sourceforge.groboutils.junit.v1; 28 29 import org.apache.log4j.Logger; 30 import junit.framework.TestCase; 31 import junit.framework.TestResult; 32 import junit.framework.AssertionFailedError; 33 import junit.framework.Assert; 34 35 import java.util.Hashtable ; 36 37 38 46 public class IntegrationTestCase extends SubTestTestCase 47 { 48 private AssertTestFactory atf; 49 50 51 56 public IntegrationTestCase( String name ) 57 { 58 super( name ); 59 60 this.atf = new AssertTestFactory( getName(), true ); 61 } 62 63 64 67 74 public void softAssertTrue(String message, boolean condition) 75 { 76 addSubTest( this.atf.createAssertTrue( message, condition ) ); 77 } 78 79 80 86 public void softAssertTrue(boolean condition) 87 { 88 addSubTest( this.atf.createAssertTrue( condition ) ); 89 } 90 91 92 100 public void softAssertFalse(String message, boolean condition) 101 { 102 addSubTest( this.atf.createAssertFalse( message, condition ) ); 103 } 104 105 106 113 public void softAssertFalse(boolean condition) 114 { 115 addSubTest( this.atf.createAssertFalse( condition ) ); 116 } 117 118 119 124 public void softFail(String message) 125 { 126 addSubTest( this.atf.createFail( message ) ); 127 } 128 129 130 133 public void softFail() 134 { 135 addSubTest( this.atf.createFail() ); 136 } 137 138 139 147 public void softAssertEquals(String message, Object expected, Object actual) 148 { 149 addSubTest( this.atf.createAssertEquals( message, expected, actual ) ); 150 } 151 152 153 160 public void softAssertEquals(Object expected, Object actual) 161 { 162 addSubTest( this.atf.createAssertEquals( expected, actual ) ); 163 } 164 165 166 175 public void softAssertEquals(String message, String expected, String actual) 176 { 177 addSubTest( this.atf.createAssertEquals( message, expected, actual ) ); 178 } 179 180 181 189 public void softAssertEquals(String expected, String actual) 190 { 191 addSubTest( this.atf.createAssertEquals( expected, actual ) ); 192 } 193 194 195 204 public void softAssertEquals(String message, double expected, 205 double actual, double delta) 206 { 207 addSubTest( this.atf.createAssertEquals( message, expected, actual, 208 delta ) ); 209 } 210 211 212 220 public void softAssertEquals(double expected, double actual, double delta) 221 { 222 addSubTest( this.atf.createAssertEquals( expected, actual, delta ) ); 223 } 224 225 226 235 public void softAssertEquals(String message, float expected, float actual, 236 float delta) 237 { 238 addSubTest( this.atf.createAssertEquals( message, expected, actual, 239 delta ) ); 240 } 241 242 243 251 public void softAssertEquals(float expected, float actual, float delta) 252 { 253 addSubTest( this.atf.createAssertEquals( expected, actual, delta ) ); 254 } 255 256 257 264 public void softAssertEquals(String message, long expected, long actual) 265 { 266 addSubTest( this.atf.createAssertEquals( message, expected, actual ) ); 267 } 268 269 270 276 public void softAssertEquals(long expected, long actual) 277 { 278 addSubTest( this.atf.createAssertEquals( expected, actual ) ); 279 } 280 281 282 289 public void softAssertEquals(String message, boolean expected, 290 boolean actual) 291 { 292 addSubTest( this.atf.createAssertEquals( message, expected, actual ) ); 293 } 294 295 296 302 public void softAssertEquals(boolean expected, boolean actual) 303 { 304 addSubTest( this.atf.createAssertEquals( expected, actual ) ); 305 } 306 307 308 315 public void softAssertEquals(String message, byte expected, byte actual) 316 { 317 addSubTest( this.atf.createAssertEquals( message, expected, actual ) ); 318 } 319 320 321 327 public void softAssertEquals(byte expected, byte actual) 328 { 329 addSubTest( this.atf.createAssertEquals( expected, actual ) ); 330 } 331 332 333 340 public void softAssertEquals(String message, char expected, char actual) 341 { 342 addSubTest( this.atf.createAssertEquals( message, expected, actual ) ); 343 } 344 345 346 352 public void softAssertEquals(char expected, char actual) 353 { 354 addSubTest( this.atf.createAssertEquals( expected, actual ) ); 355 } 356 357 358 365 public void softAssertEquals(String message, short expected, short actual) 366 { 367 addSubTest( this.atf.createAssertEquals( message, expected, actual ) ); 368 } 369 370 371 377 public void softAssertEquals(short expected, short actual) 378 { 379 addSubTest( this.atf.createAssertEquals( expected, actual ) ); 380 } 381 382 383 390 public void softAssertEquals(String message, int expected, int actual) 391 { 392 addSubTest( this.atf.createAssertEquals( message, expected, actual ) ); 393 } 394 395 396 402 public void softAssertEquals(int expected, int actual) 403 { 404 addSubTest( this.atf.createAssertEquals( expected, actual ) ); 405 } 406 407 408 414 public void softAssertNotNull(String message, Object object) 415 { 416 addSubTest( this.atf.createAssertNotNull( message, object ) ); 417 } 418 419 420 425 public void softAssertNotNull(Object object) 426 { 427 addSubTest( this.atf.createAssertNotNull( object ) ); 428 } 429 430 431 437 public void softAssertNull(String message, Object object) 438 { 439 addSubTest( this.atf.createAssertNull( message, object ) ); 440 } 441 442 443 448 public void softAssertNull(Object object) 449 { 450 addSubTest( this.atf.createAssertNull( object ) ); 451 } 452 453 454 462 public void softAssertSame(String message, Object expected, Object actual) 463 { 464 addSubTest( this.atf.createAssertSame( message, expected, actual ) ); 465 } 466 467 468 475 public void softAssertSame(Object expected, Object actual) 476 { 477 addSubTest( this.atf.createAssertSame( expected, actual ) ); 478 } 479 480 481 490 public void softAssertNotSame(String message, Object expected, Object actual) 491 { 492 addSubTest( this.atf.createAssertNotSame( message, expected, actual ) ); 493 } 494 495 496 504 public void softAssertNotSame(Object expected, Object actual) 505 { 506 addSubTest( this.atf.createAssertNotSame( expected, actual ) ); 507 } 508 } 509 510 | Popular Tags |