Upgrading to JUnit 4.7. Changing two classes (ClassNotFoundSerializationTest and CharUtilsPerfTest) to not end with Test as that was throwing them into the JUnit setup. CharUtilsPerfTest renamed to CharUtilsPerfRun. ClassNotFoundSerializationTest becomes ClassNotFoundSerialization.
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/lang/trunk@824595 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
parent
169a20fb98
commit
1e282a9643
3
pom.xml
3
pom.xml
|
@ -401,11 +401,10 @@
|
|||
|
||||
<!-- Lang should depend on very little -->
|
||||
<dependencies>
|
||||
<!-- TODO: replace with TestNG -->
|
||||
<dependency>
|
||||
<groupId>junit</groupId>
|
||||
<artifactId>junit</artifactId>
|
||||
<version>3.8.2</version>
|
||||
<version>4.7</version>
|
||||
<scope>test</scope>
|
||||
</dependency>
|
||||
</dependencies>
|
||||
|
|
|
@ -56,7 +56,7 @@ run_inlined_CharUtils_isAsciiNumeric: 84,420 milliseconds.
|
|||
|
||||
* @version $Id$
|
||||
*/
|
||||
public class CharUtilsPerfTest {
|
||||
public class CharUtilsPerfRun {
|
||||
final static String VERSION = "$Id$";
|
||||
|
||||
final static int WARM_UP = 100;
|
||||
|
@ -72,7 +72,7 @@ public class CharUtilsPerfTest {
|
|||
}
|
||||
|
||||
public static void main(String[] args) {
|
||||
new CharUtilsPerfTest().run();
|
||||
new CharUtilsPerfRun().run();
|
||||
}
|
||||
|
||||
private void printSysInfo() {
|
|
@ -42,7 +42,7 @@ import junit.textui.TestRunner;
|
|||
*/
|
||||
public class SerializationUtilsTest extends TestCase {
|
||||
|
||||
static final String CLASS_NOT_FOUND_MESSAGE = "ClassNotFoundSerializationTest.readObject fake exception";
|
||||
static final String CLASS_NOT_FOUND_MESSAGE = "ClassNotFoundSerialization.readObject fake exception";
|
||||
protected static final String SERIALIZE_IO_EXCEPTION_MESSAGE = "Anonymous OutputStream I/O exception";
|
||||
|
||||
private String iString;
|
||||
|
@ -252,7 +252,7 @@ public class SerializationUtilsTest extends TestCase {
|
|||
public void testDeserializeStreamClassNotFound() throws Exception {
|
||||
ByteArrayOutputStream streamReal = new ByteArrayOutputStream();
|
||||
ObjectOutputStream oos = new ObjectOutputStream(streamReal);
|
||||
oos.writeObject(new ClassNotFoundSerializationTest());
|
||||
oos.writeObject(new ClassNotFoundSerialization());
|
||||
oos.flush();
|
||||
oos.close();
|
||||
|
||||
|
@ -391,10 +391,10 @@ public class SerializationUtilsTest extends TestCase {
|
|||
|
||||
}
|
||||
|
||||
class ClassNotFoundSerializationTest implements Serializable
|
||||
class ClassNotFoundSerialization implements Serializable
|
||||
{
|
||||
|
||||
private void readObject(ObjectInputStream in) throws IOException, ClassNotFoundException {
|
||||
throw new ClassNotFoundException(SerializationUtilsTest.CLASS_NOT_FOUND_MESSAGE);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue