MCPcopy Index your code
hub / github.com/OpenTSDB/opentsdb / handleTreePOSTModify

Method handleTreePOSTModify

test/tsd/TestTreeRpc.java:258–269  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

256 }
257
258 @Test
259 public void handleTreePOSTModify() throws Exception {
260 setupStorage();
261 HttpQuery query = NettyMocks.postQuery(tsdb,
262 "/api/tree", "{\"treeId\":1,\"description\":\"Hello World\"}");
263 rpc.execute(tsdb, query);
264 assertEquals(HttpResponseStatus.OK, query.response().getStatus());
265 assertTrue(query.response().getContent().toString(MockBase.ASCII())
266 .contains("\"description\":\"Hello World\""));
267 assertTrue(query.response().getContent().toString(MockBase.ASCII())
268 .contains("\"name\":\"Test Tree\""));
269 }
270
271 @Test (expected = BadRequestException.class)
272 public void handleTreeQSPutNotFound() throws Exception {

Callers

nothing calls this directly

Calls 9

setupStorageMethod · 0.95
postQueryMethod · 0.95
ASCIIMethod · 0.95
responseMethod · 0.80
containsMethod · 0.80
executeMethod · 0.65
getStatusMethod · 0.65
toStringMethod · 0.45
getContentMethod · 0.45

Tested by

no test coverage detected