[jboss-cvs] JBossAS SVN: r85232 - in trunk/testsuite: src/etc/serialVersionUID and 1 other directories.
jboss-cvs-commits at lists.jboss.org
jboss-cvs-commits at lists.jboss.org
Wed Mar 4 10:42:59 EST 2009
Author: smcgowan at redhat.com
Date: 2009-03-04 10:42:55 -0500 (Wed, 04 Mar 2009)
New Revision: 85232
Added:
trunk/testsuite/src/etc/serialVersionUID/500.ser
trunk/testsuite/src/etc/serialVersionUID/501.ser
Modified:
trunk/testsuite/build.xml
trunk/testsuite/src/main/org/jboss/test/compatibility/test/SerialVersionUIDUnitTestCase.java
Log:
JBAS-6555 - SerialVersionUIDUnitTestCase updates
Modified: trunk/testsuite/build.xml
===================================================================
--- trunk/testsuite/build.xml 2009-03-04 15:24:41 UTC (rev 85231)
+++ trunk/testsuite/build.xml 2009-03-04 15:42:55 UTC (rev 85232)
@@ -2000,7 +2000,8 @@
<sysproperty key="jbosstest.deploy.dir" file="${build.lib}"/>
<sysproperty key="build.testlog" value="${build.testlog}"/>
<sysproperty key="log4j.configuration" value="file:${build.resources}/log4j.xml"/>
- <sysproperty key="jboss.aop.path" file="${source.resources}/cache/standalone/META-INF/jboss-aop.xml"/>
+ <sysproperty key="java.endorsed.dirs" value="${jboss.dist}/lib/endorsed"/>
+
<!-- Pass along any jbosstest.* system properties -->
<syspropertyset>
<propertyref prefix="jbosstest."/>
Added: trunk/testsuite/src/etc/serialVersionUID/500.ser
===================================================================
(Binary files differ)
Property changes on: trunk/testsuite/src/etc/serialVersionUID/500.ser
___________________________________________________________________
Name: svn:mime-type
+ application/octet-stream
Added: trunk/testsuite/src/etc/serialVersionUID/501.ser
===================================================================
(Binary files differ)
Property changes on: trunk/testsuite/src/etc/serialVersionUID/501.ser
___________________________________________________________________
Name: svn:mime-type
+ application/octet-stream
Modified: trunk/testsuite/src/main/org/jboss/test/compatibility/test/SerialVersionUIDUnitTestCase.java
===================================================================
--- trunk/testsuite/src/main/org/jboss/test/compatibility/test/SerialVersionUIDUnitTestCase.java 2009-03-04 15:24:41 UTC (rev 85231)
+++ trunk/testsuite/src/main/org/jboss/test/compatibility/test/SerialVersionUIDUnitTestCase.java 2009-03-04 15:42:55 UTC (rev 85232)
@@ -59,21 +59,34 @@
{
// The packages in jboss-4.2.3 with known serialization issues
String[] badPackages = {
- // Ignore org.apache.* issues
- "org.apache",
- // Ignore jgroups issues
- "org.jgroups",
- //JBAS-5872 - serialVersionUID mismatches from 4.2.3.GA to be resolved
- "org.jboss.aspects.versioned.StateManager",
- "org.jboss.cache.CacheException",
- "org.jboss.cache.Fqn",
- "org.jboss.cache.Modification",
- "org.jboss.cache.ReplicationException",
- "org.jboss.logging.XLevel",
- "org.jboss.mx.util.InstanceOfQueryExp",
- "org.jboss.virtual.plugins.context.jar.NestedJarFromStream",
- // Exclude due to mismatch when running with JDK 6
- "javax.xml.ws.soap.SOAPFaultException"
+ "com.arjuna.ats.internal.jbossatx.jta.PropagationContextManager",
+ // Ignore org.apache.* issues
+ "org.apache",
+ // Ignore hibernate issues
+ "org.hibernate",
+ // Ignore jgroups issues
+ "org.jgroups",
+ //JBAS-5872 - serialVersionUID mismatches from 4.2.3.GA to be resolved
+ "org.jboss.aspects.versioned.StateManager",
+ "org.jboss.cache.CacheException",
+ "org.jboss.cache.Fqn",
+ "org.jboss.cache.Modification",
+ "org.jboss.cache.ReplicationException",
+ "org.jboss.logging.XLevel",
+ "org.jboss.mx.util.InstanceOfQueryExp",
+ "org.jboss.virtual.plugins.context.jar.NestedJarFromStream",
+ "org.jboss.console",
+ "org.jboss.ejb3.stateful.StatefulBeanContextReference",
+ "org.jboss.iiop",
+ "org.jboss.security.NestableGroup",
+ "org.jboss.security.NestablePrincipal",
+ "org.jboss.tm.iiop._TransactionServiceStub",
+ "org.jboss.wsf",
+ // other
+ "javax.xml.registry.JAXRException",
+ "javax.xml.registry.RegistryException",
+ // lib/endorsed/stax-api.jar
+ "javax.xml.namespace.QName"
};
System.out.println("+++ test423Compatibility");
@@ -85,7 +98,6 @@
Map classInfoMap = (Map) ois.readObject();
System.out.println("4.2.3 serial classes count: "+classInfoMap.size());
- System.setProperty("org.jboss.j2ee.LegacySerialization", "true");
Map currentClassInfoMap = calcClassInfoMap();
int mismatchCount = compare(classInfoMap, currentClassInfoMap, "423", badPackages);
currentClassInfoMap.clear();
@@ -94,6 +106,98 @@
mismatchCount == 0);
}
+ /** Validate the 5.0.0.GA serial version uids against the current build
+ * @throws Exception
+ */
+ public void test500Compatibility()
+ throws Exception
+ {
+ // The packages in jboss-5.0.0.GA with known serialization issues
+ String[] badPackages = {
+ "org.apache.catalina",
+ "org.jboss.classloading.spi.dependency.Module",
+ "org.jboss.console",
+ // those were changed to match 423 ids
+ "org.jboss.crypto.JBossSXProvider",
+ "org.jboss.metadata.rar.spec.JCA15MetaData",
+ "org.jboss.resource.adapter.jdbc.CachedPreparedStatement",
+ "org.jboss.resource.metadata.ConnectorMetaData",
+ "org.jboss.resource.metadata.DescriptionMetaDataContainer",
+ "org.jboss.security.SimplePrincipal",
+ "org.jboss.security.SubjectSecurityProxyFactory",
+ "org.jboss.services.binding.DuplicateServiceException",
+ // unclear if vfs classes are serialized to client
+ "org.jboss.virtual.plugins.context.vfs.AssembledDirectoryHandler",
+ "org.jboss.virtual.plugins.context.zip.ZipEntryHandler",
+ // ignore webservices framework classes
+ "org.jboss.wsf",
+ // lib/endorsed/stax-api.jar
+ "javax.xml.namespace.QName"
+ };
+ System.out.println("+++ test500Compatibility");
+ // load the 5.0.0 serialVersionUID database
+ String etc = System.getProperty("jbosstest.src.etc", "../src/etc");
+ File serFile = new File(etc, "serialVersionUID/500.ser");
+ FileInputStream fis = new FileInputStream(serFile);
+ ObjectInputStream ois = new ObjectInputStream(fis);
+ Map classInfoMap = (Map) ois.readObject();
+ System.out.println("5.0.0.GA serial classes count: "+classInfoMap.size());
+
+ Map currentClassInfoMap = calcClassInfoMap();
+ int mismatchCount = compare(classInfoMap, currentClassInfoMap, "500", badPackages);
+ currentClassInfoMap.clear();
+ System.out.println("serialVersionUID mismatches = "+mismatchCount);
+ assertTrue("There are no serialVersionUID mismatches("+mismatchCount+")",
+ mismatchCount == 0);
+ }
+
+ /** Validate the 5.0.1.GA serial version uids against the current build
+ * @throws Exception
+ */
+ public void test501Compatibility()
+ throws Exception
+ {
+ // The packages in jboss-5.0.1.GA with known serialization issues
+ String[] badPackages = {
+ "org.apache.catalina",
+ "org.jboss.classloading.spi.dependency.Module",
+ "org.jboss.console",
+ // those were changed to match 423 ids
+ "org.jboss.crypto.JBossSXProvider",
+ "org.jboss.metadata.rar.spec.JCA15MetaData",
+ "org.jboss.resource.adapter.jdbc.CachedPreparedStatement",
+ "org.jboss.resource.metadata.ConnectorMetaData",
+ "org.jboss.resource.metadata.DescriptionMetaDataContainer",
+ "org.jboss.security.SimplePrincipal",
+ "org.jboss.security.SubjectSecurityProxyFactory",
+ "org.jboss.services.binding.DuplicateServiceException",
+ // unclear if vfs classes are serialized to client
+ "org.jboss.virtual.plugins.context.vfs.AssembledDirectoryHandler",
+ "org.jboss.virtual.plugins.context.zip.ZipEntryHandler",
+ // ignore webservices framework classes
+ "org.jboss.wsf",
+ // lib/endorsed/stax-api.jar
+ "javax.xml.namespace.QName"
+ };
+
+ System.out.println("+++ test501Compatibility");
+ // load the 5.0.1.GA serialVersionUID database
+ String etc = System.getProperty("jbosstest.src.etc", "../src/etc");
+ File serFile = new File(etc, "serialVersionUID/501.ser");
+ FileInputStream fis = new FileInputStream(serFile);
+ ObjectInputStream ois = new ObjectInputStream(fis);
+ Map classInfoMap = (Map) ois.readObject();
+ System.out.println("5.0.1.GA serial classes count: "+classInfoMap.size());
+
+ Map currentClassInfoMap = calcClassInfoMap();
+ int mismatchCount = compare(classInfoMap, currentClassInfoMap, "501", badPackages);
+ currentClassInfoMap.clear();
+ System.out.println("serialVersionUID mismatches = "+mismatchCount);
+ assertTrue("There are no serialVersionUID mismatches("+mismatchCount+")",
+ mismatchCount == 0);
+ }
+
+
/** Validate the JavaEE 5.0 RI serial version uids against the current build
* @throws Exception
*/
@@ -103,12 +207,23 @@
// The packages to e excluded known serialization issues
String[] badPackages = {
// Ignore org.apache.* issues
- "org.apache",
- //JBAS-5872 - serialVersionUID mismatches from JavaEE 5.0 RI to be resolved
+ "org.apache",
"com.sun.faces.config.JSFVersionTracker",
"com.sun.faces.lifecycle.ELResolverInitPhaseListener",
+ "com.sun.faces.taglib.jsf_core.ConverterTag",
+ "com.sun.faces.taglib.jsf_core.LoadBundleTag",
+ "com.sun.faces.taglib.jsf_core.PhaseListenerTag",
+ "com.sun.faces.taglib.jsf_core.ValidatorTag",
+ "javax.servlet.GenericServlet",
+ "javax.servlet.ServletException",
+ "javax.xml.registry.JAXRException",
+ "javax.xml.registry.RegistryException",
+ "javax.persistence.OptimisticLockException",
+ "javax.ejb.ConcurrentAccessException",
"javax.faces.component.UIComponentBase$ChildrenList",
"javax.faces.component.UIComponentBase$FacetsMap",
+ "javax.faces.component.UIComponentBase$AttributesMap",
+ "javax.xml.ws.soap.SOAPFaultException",
"org.omg.CosTransactions.Status",
"org.omg.CosTransactions.Vote",
"org.omg.CosTransactions._ControlStub",
@@ -168,11 +283,11 @@
if( isInBadPkg == false )
{
mismatchCount ++;
- System.err.println(msg);
+ System.err.println("FAIL: " + msg);
}
else
{
- System.out.println(msg);
+ System.out.println("EXCLUDED: " + msg);
}
}
}
@@ -186,8 +301,7 @@
File jbossHome = new File(jbossDist);
jbossHome = jbossHome.getCanonicalFile();
System.out.println("Calculating serialVersionUIDs for jbossHome: "+jbossHome);
- Map classInfoMap = SerialVersionUID.generateJBossSerialVersionUIDReport(
- jbossHome);
+ Map classInfoMap = SerialVersionUID.generateJBossSerialVersionUIDReport(jbossHome);
return classInfoMap;
}
@@ -197,7 +311,9 @@
// so it must be defined explicitly when running under some JVMs
TestSuite suite = new TestSuite();
suite.addTest(new SerialVersionUIDUnitTestCase("test423Compatibility"));
- //suite.addTest(new SerialVersionUIDUnitTestCase("testJavaEE50Compatibility"));
+ suite.addTest(new SerialVersionUIDUnitTestCase("test500Compatibility"));
+ suite.addTest(new SerialVersionUIDUnitTestCase("test501Compatibility"));
+ suite.addTest(new SerialVersionUIDUnitTestCase("testJavaEE50Compatibility"));
return suite;
}
More information about the jboss-cvs-commits
mailing list