DATACOUCH-34 - Can't deserialize long/Long/Date fields.
Make the test more robust, check the set value against the returned value.
This commit is contained in:
@@ -201,10 +201,12 @@ public class CouchbaseTemplateTests {
|
|||||||
|
|
||||||
@Test
|
@Test
|
||||||
public void shouldDeserialiseLongs() {
|
public void shouldDeserialiseLongs() {
|
||||||
SimpleWithLong simpleWithLong = new SimpleWithLong("simpleWithLong:simple", new Date().getTime());
|
final long time = new Date().getTime();
|
||||||
|
SimpleWithLong simpleWithLong = new SimpleWithLong("simpleWithLong:simple", time);
|
||||||
template.save(simpleWithLong);
|
template.save(simpleWithLong);
|
||||||
simpleWithLong = template.findById("simpleWithLong:simple", SimpleWithLong.class);
|
simpleWithLong = template.findById("simpleWithLong:simple", SimpleWithLong.class);
|
||||||
assertNotNull(simpleWithLong);
|
assertNotNull(simpleWithLong);
|
||||||
|
assertEquals(time, simpleWithLong.getValue());
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|||||||
Reference in New Issue
Block a user