Add tests for serialisation of Booleans and Numbers in cells

This commit is contained in:
Owen Stephens 2019-04-04 11:41:35 +01:00
parent ebaad96dfc
commit 62bcc80dcc

View File

@ -95,4 +95,18 @@ public class CellTests {
String json = "{\"v\":\"2018-03-04T08:09:10Z\",\"t\":\"date\"}"; String json = "{\"v\":\"2018-03-04T08:09:10Z\",\"t\":\"date\"}";
TestUtils.isSerializedTo(Cell.loadStreaming(json, pool), json); TestUtils.isSerializedTo(Cell.loadStreaming(json, pool), json);
} }
@Test
public void serializeNumberCell() throws Exception {
String json = "{\"v\": 1}";
Cell c = Cell.loadStreaming(json, pool);
TestUtils.isSerializedTo(c, json);
}
@Test
public void serializeBooleanCell() throws Exception {
String json = "{\"v\": true}";
Cell c = Cell.loadStreaming(json, pool);
TestUtils.isSerializedTo(c, json);
}
} }