1 26 27 package net.sourceforge.groboutils.junit.v1; 28 29 import junit.framework.Test; 31 import junit.framework.TestCase; 32 import junit.framework.TestSuite; 33 34 import java.io.IOException ; 35 import java.lang.reflect.Method ; 36 37 38 46 public class JUnitTestSuiteEUTest extends TestCase 47 { 48 51 private static final Class THIS_CLASS = JUnitTestSuiteEUTest.class; 52 54 public JUnitTestSuiteEUTest( String name ) 55 { 56 super( name ); 57 } 58 59 60 61 62 65 66 public void testConstructor1() 67 { 68 try 69 { 70 new TestSuite( (Class )null ); 71 fail( "Did not throw NullPointerException." ); 72 } 73 catch (NullPointerException e) 74 { 75 } 77 } 78 79 80 public void testGetTestAt1() 81 { 82 TestSuite ts = new TestSuite(); 83 84 try 85 { 86 ts.testAt( 0 ); 87 fail( "Did not throw ArrayIndexOutOfBoundsException." ); 88 } 89 catch (ArrayIndexOutOfBoundsException e) 90 { 91 } 93 } 94 95 96 public void testSetName1() 97 { 98 TestSuite ts = new TestSuite(); 99 100 ts.setName( null ); 101 } 102 103 104 105 108 109 public static Test suite() 110 { 111 TestSuite suite = new TestSuite( THIS_CLASS ); 112 113 return suite; 114 } 115 116 public static void main( String [] args ) 117 { 118 String [] name = { THIS_CLASS.getName() }; 119 120 123 junit.textui.TestRunner.main( name ); 124 } 125 126 127 131 protected void setUp() throws Exception 132 { 133 super.setUp(); 134 135 } 137 138 139 143 protected void tearDown() throws Exception 144 { 145 147 148 super.tearDown(); 149 } 150 } 151 152 | Popular Tags |