01: /*
02: * All content copyright (c) 2003-2006 Terracotta, Inc., except as may otherwise be noted in a separate copyright notice. All rights reserved.
03: */
04: package com.tc.object.dna.impl;
05:
06: import com.tc.io.TCByteBufferOutputStream;
07: import com.tc.object.ObjectID;
08: import com.tc.object.dna.api.DNAWriter;
09: import com.tc.object.dna.api.DNAEncoding;
10:
11: public class ObjectDNAImplTest extends DNAImplTest {
12:
13: private long version = 69;
14:
15: public void testSerializeDeserialize() throws Exception {
16: super .testSerializeDeserialize();
17: assertEquals(version, dna.getVersion());
18: }
19:
20: protected void assertOverridable() {
21: assertFalse(dna.isDelta());
22: }
23:
24: protected boolean getIsDelta() {
25: return false;
26: }
27:
28: protected DNAImpl createDNAImpl(ObjectStringSerializer serializer,
29: boolean b) {
30: return new ObjectDNAImpl(serializer, b);
31: }
32:
33: protected DNAWriter createDNAWriter(TCByteBufferOutputStream out,
34: ObjectID id, String type,
35: ObjectStringSerializer serializer, DNAEncoding encoding,
36: String string) {
37: return new ObjectDNAWriterImpl(out, id, type, serializer,
38: encoding, "loader description", version);
39: }
40:
41: }
|