MCPcopy
hub / github.com/OpenTSDB/opentsdb / parseToObjectByteString

Method parseToObjectByteString

test/utils/TestJSON.java:99–107  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

97 }
98
99 @Test
100 public void parseToObjectByteString() throws Exception {
101 @SuppressWarnings("unchecked")
102 HashMap<String, String> map = JSON.parseToObject(
103 "{\"utf\":\"aeriennes\",\"ascii\":\"aariennes\"}".getBytes(),
104 HashMap.class);
105 assertEquals("aeriennes", map.get("utf"));
106 assertEquals("aariennes", map.get("ascii"));
107 }
108
109 @Test (expected = IllegalArgumentException.class)
110 public void parseToObjectByteNull() throws Exception {

Callers

nothing calls this directly

Calls 3

parseToObjectMethod · 0.95
getBytesMethod · 0.45
getMethod · 0.45

Tested by

no test coverage detected