use of com.orientechnologies.orient.core.serialization.serializer.record.binary.BytesContainer in project orientdb by orientechnologies.
the class OVarIntSerializerTest method serializeMaxLong.
@Test
public void serializeMaxLong() {
BytesContainer bytes = new BytesContainer();
bytes.offset = OVarIntSerializer.write(bytes, Long.MAX_VALUE);
assertEquals(OVarIntSerializer.readAsLong(bytes), Long.MAX_VALUE);
}
use of com.orientechnologies.orient.core.serialization.serializer.record.binary.BytesContainer in project orientdb by orientechnologies.
the class OVarIntSerializerTest method serializeNegative.
@Test
public void serializeNegative() {
BytesContainer bytes = new BytesContainer();
OVarIntSerializer.write(bytes, -20432343);
bytes.offset = 0;
assertEquals(OVarIntSerializer.readAsLong(bytes), -20432343l);
}
Aggregations