@@ -0,0 +1,2203 @@
+package org.mapdb;%0A%0Aimport junit.framework.TestCase;%0A%0Aimport java.io.*;%0Aimport java.util.concurrent.CopyOnWriteArrayList;%0A%0A/**%0A * Alexandre Y. Bouchov%0A * Date: 27.08.14%0A * Time: 11:04%0A */%0Apublic class Issue373Test extends TestCase %7B%0A    SerializerPojo p = new SerializerPojo(new CopyOnWriteArrayList%3CSerializerPojo.ClassInfo%3E());%0A%0A    public static class NotSerializableClass %7B%0A    %7D%0A%0A    public static class Pojo2 implements Serializable %7B%0A        private Class classVal;%0A%0A        public Pojo2(Class classVal) %7B%0A            this.classVal = classVal;%0A        %7D%0A    %7D%0A%0A    public static class Pojo implements Serializable %7B%0A        private static final int VERSION = 0;%0A        private transient Pojo2 pojo2Val;%0A%0A        public Pojo(Pojo2 pojo2Val) %7B%0A            this.pojo2Val = pojo2Val;%0A        %7D%0A%0A        private void writeObject(ObjectOutputStream out)%0A                throws IOException %7B%0A            out.defaultWriteObject();%0A            out.writeInt(VERSION);%0A            out.writeObject(pojo2Val);%0A        %7D%0A%0A        private void readObject(ObjectInputStream in)%0A                throws IOException, ClassNotFoundException %7B%0A            in.defaultReadObject();%0A            int ver = in.readInt();%0A            if (ver == 0) %7B%0A                pojo2Val = (Pojo2) in.readObject();%0A            %7D else %7B%0A                throw new IOException(%22Unknown class version (%22 + ver + ')');%0A            %7D%0A        %7D%0A    %7D%0A%0A    public static class SimplePojo implements Serializable %7B%0A        private Pojo2 pojo2Val;%0A%0A        public SimplePojo(Pojo2 pojo2Val) %7B%0A            this.pojo2Val = pojo2Val;%0A        %7D%0A%0A        public Pojo2 getPojo2Val() %7B%0A            return pojo2Val;%0A        %7D%0A    %7D%0A%0A    public void test_Pojo2() throws Exception %7B%0A        serialize(new Pojo2(NotSerializableClass.class));%0A    %7D%0A%0A    public void test_SimplePojo() throws Exception %7B%0A        serialize(new SimplePojo(new Pojo2(NotSerializableClass.class)));%0A    %7D%0A%0A    public void test_Pojo() throws Exception %7B%0A        serialize(new Pojo(new Pojo2(NotSerializableClass.class)));%0A    %7D%0A%0A    private void serialize(Object i) throws IOException %7B%0A        DataOutput in = new DataIO.DataOutputByteArray();%0A        p.serialize(in, i);%0A    %7D%0A%7D

Fix #373: SerializerPojo throws NotSerializableException for Class field