Package com.thoughtworks.proxy.kit

Examples of com.thoughtworks.proxy.kit.NoOperationResetter


        useSerializedProxy((Pool)serializeWithXStreamAndPureReflection(pool));
        assertNotNull(borrowed); // keep instance
    }

    public void testForcedSerializationWithUnserializableObject() throws IOException, ClassNotFoundException {
        final Pool pool = new Pool(TestCase.class, new NoOperationResetter(), getFactory(), Pool.SERIALIZATION_FORCE);
        pool.add(this);
        final Pool serialized = (Pool)serializeWithJDK(pool);
        assertEquals(0, serialized.size());
        serialized.add(this);
        assertEquals(1, serialized.size());
View Full Code Here


        serialized.add(this);
        assertEquals(1, serialized.size());
    }

    public void testForcedSerializationWithEmptyPool() throws IOException, ClassNotFoundException {
        final Pool pool = new Pool(Identifiable.class, new NoOperationResetter(), getFactory(), Pool.SERIALIZATION_NONE);
        pool.add(createIdentifiables(2));
        final Pool serialized = (Pool)serializeWithJDK(pool);
        assertEquals(0, serialized.size());
    }
View Full Code Here

TOP

Related Classes of com.thoughtworks.proxy.kit.NoOperationResetter

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.