### Question:
ZkRing extends AbstractRing { public static ZkRing create(ZooKeeperPlus zk, Coordinator coordinator, String ringGroup, int ringNum, RingGroup group, DataLocationChangeListener dataLocationChangeListener) throws KeeperException, InterruptedException { String ringPath = ZkPath.append(ringGroup, "ring-" + ringNum); zk.create(ringPath, null); zk.create(ZkPath.append(ringPath, HOSTS_PATH_SEGMENT), null); return new ZkRing(zk, ringPath, group, coordinator, dataLocationChangeListener); } ZkRing(ZooKeeperPlus zk,
                final String ringPath,
                RingGroup ringGroup,
                final Coordinator coordinator,
                final DataLocationChangeListener dataLocationChangeListener); static ZkRing create(ZooKeeperPlus zk,
                              Coordinator coordinator,
                              String ringGroup,
                              int ringNum,
                              RingGroup group,
                              DataLocationChangeListener dataLocationChangeListener); @Override Set<Host> getHosts(); @Override Host getHostByAddress(PartitionServerAddress address); @Override Host addHost(PartitionServerAddress address,
                      List<String> flags); @Override boolean removeHost(PartitionServerAddress address); void close(); void delete();  }### Answer:
@Test public void testCreate() throws Exception { ZkRing ring = ZkRing.create(getZk(), coordinator, ring_group_root, 1, null, null); assertEquals("ring number", 1, ring.getRingNumber()); assertEquals("number of hosts", 0, ring.getHosts().size()); ring.close(); }