### Question:
ClusterController extends Controller { @Action(method = HttpMethod.POST) public ActionResult push_instance_config(HttpContext context) { Map<String, List<HttpBody>> map = context.Request.getBodies(); logger.info("bodies:" + JacksonUtils.toJson(map)); JsonResult jsonResult = clusterService.pushInstanceConfig(map); String result = JacksonUtils.toJson(jsonResult); logger.info("jsonResult:" + result); ActionResult actionResult = null; try { actionResult = new ActionResult(HttpDataType.JSON, result.getBytes(Constants.DEFAULT_CHARSET)); } catch (UnsupportedEncodingException e) { actionResult = new ActionResult(HttpDataType.JSON, result.getBytes()); logger.error(e); } return actionResult; }  @Action(method = HttpMethod.POST) ActionResult push_cluster_config(HttpContext context); @Action(method = HttpMethod.POST) ActionResult push_instance_config(HttpContext context);  }### Answer:
@Test public void push_instance_configTest(){ ConfigManager.getInstance().put(ConfigManager.KEY_ZKSTR, server.getConnectString()); System.out.println(ZkInstanceUtil.getInstance().getClientState()); ClusterController clusterController = new ClusterController(); HttpContext context = new HttpContext(UUID.randomUUID().toString()); Map<String, String> params = new HashMap<>(); params.put(Constants.ZK_NODE_PATH, "/root"); params.put(Constants.ZK_NODE_PUSHID, "1111"); context.Request.setParams(params); HttpBody httpBody = new HttpBody(); httpBody.setParams(params); httpBody.setContentData("test".getBytes()); List<HttpBody> list = new ArrayList<>(); Map<String, List<HttpBody>> bodies = new HashMap<>(); bodies.put(Constants.CONTENT_TYPE_OCTET_STREAM, list); context.Request.setBodies(bodies); ActionResult result = null; result = clusterController.push_instance_config(context); Assert.assertNotNull(result.getData()); byte[] data = result.getData(); String str = new String(data); JsonResult jsonResult = JacksonUtils.toObject(str, JsonResult.class); Assert.assertEquals(0, jsonResult.getRet()); System.out.println( ZkInstanceUtil.checkZkHelper()); }