
README for Unit Testing of SerialVerify.

The directory ORIGINALCLASSES contains the classes that should
be used with the -setup flag in the SerialVerify program.

So copy the classes from the directory into this one. compile them.

Then:

java SerialVerify -v -setup testfile unittest

Then copy the classes from the CHANGEDCLASSES to this one. compile them.

Then:

java SerialVerify -v -verify testfile.


This will print out error messages as to what changed from the ORIGINALCLASSES
to the EVOLVEDCLASSES that should not have changed.

Sample output:

cd unittest; make EvolvedClasses
cd EVOLVEDCLASSES; javac -d ../.. addfield.java  addsuper.java  changeEtoS.java  changeStoE.java  changefieldtype.java  changefromstatic.java  changefromtransient.java  changehierarchy.java  changetostatic.java  changetotransient.java  deletefield.java  delsuper.java  removeE.java  removeS.java
java SerialVerify -verify unittest.ref

In Class unittest.delsuper
Change: a superclass deleted -> unittest.newsuper

In Class unittest.changehierarchy
Error: classes have moved up/down in hierarchy: unittest.asuper unittest.changehierarchy. 
This is an incompatible change. 

Change: a superclass deleted -> unittest.asuper

In Class unittest.changefieldtype
Error: field type changed for field -> wasboolean from boolean to int. 
This is an incompatible change. 

Error: field type changed for field -> waschar from char to class java.lang.String. 
This is an incompatible change. 

Error: field type changed for field -> wasint from int to boolean. 
This is an incompatible change. 

Error: field type changed for field -> wasstring from class java.lang.String to char. 
This is an incompatible change. 

Error: SUID changed from 3652279174711914029 to 4391143459436934230.
This is an incompatible change. 


In Class unittest.changefromtransient
Change: persistent field added -> wastransient	  
Error: SUID changed from -6597332871722832398 to 7595638381938390623.
This is an incompatible change. 


In Class unittest.addsuper
Change: new superclass added -> unittest.newsuper

In Class unittest.changeStoE
Error: Serializable Changed to Externalizable. 
This is an incompatible change.


In Class unittest.changefromstatic
Change: persistent field added -> i	  
Error: SUID changed from 546283741041036989 to 1414317289450850037.
This is an incompatible change. 


In Class unittest.changetotransient
Error: persistent field deleted -> i. 
This is an incompatible change. 

Error: SUID changed from -4287736709666654103 to -7137579208995624808.
This is an incompatible change. 


In Class unittest.addfield
Change: persistent field added -> c	  
Change: persistent field added -> b	  
Change: persistent field added -> s	  
Change: persistent field added -> i	  
Error: SUID changed from -6669024180454510197 to -1115512721503952399.
This is an incompatible change. 


In Class unittest.changeEtoS
Error: Externalizable Changed to Serializable. 
This is an incompatible change. 


In Class unittest.changetostatic
Error: persistent field deleted -> i. 
This is an incompatible change. 

Error: SUID changed from 7970205227920452231 to 9064573714682911638.
This is an incompatible change. 


In Class unittest.removeS
Error: Serializable Removed. 
This is an incompatible change.


In Class unittest.deletefield
Error: persistent field deleted -> b. 
This is an incompatible change. 

Error: persistent field deleted -> c. 
This is an incompatible change. 

Error: persistent field deleted -> i. 
This is an incompatible change. 

Error: persistent field deleted -> s. 
This is an incompatible change. 

Error: SUID changed from -678548314360338421 to 7224119051048388140.
This is an incompatible change. 


In Class unittest.removeE
Error: Externalizable Removed.
This is an incompatible change. 



The total number of serializable classes: 14
cd unittest; make clean
/bin/rm -f *.class 
 
