### Question:
DiscoveryClient { private DiscoveryClient() { pollCacheApp(); } private  DiscoveryClient(); static DiscoveryClient getInstance(); RadarInstance getInstanceRadar(); RadarClientConfig getConfig(); void setConfig(RadarClientConfig config); boolean isConfiged(); boolean isRegistered(); Map<String, RadarApp> getData(); void register(RadarInstance instanceRadar); synchronized void addAppChangedListener(AppChangedListener changeListener); Map<String, RadarApp> getApps(List<String> appIds); Map<String, RadarApp> getApps(); RadarApp getApp(String appId); void deregister(); AdjustResponse adjust(Boolean isUp);  }### Answer:
@Test public void testDiscoveryClient() throws InterruptedException, IllegalAccessException, NoSuchFieldException { RadarClientConfig config = new RadarClientConfig(rgUrl); RadarInstance instanceRadar = RadarInstance.getBuilder() .withCandInstanceId("262a15e7-6b60-432d-abdb-e939fff2fd76") .withClusterName("dc1.prd") .withCandAppId("10010001") .withAppName("RegistryInstance") .withHost("10.1.30.2") .withPort(0).build(); DiscoveryClient client = DiscoveryClient.getInstance(); client.setConfig(config); Field field = client.getClass().getDeclaredField("isStartUp"); field.setAccessible(true); field.set(client, new AtomicBoolean(false)); client.register(instanceRadar); Thread.sleep(10000); client.deregister(); }