### Question:
ZkDomain extends AbstractDomain implements Domain { public boolean delete() throws IOException { try { zk.deleteNodeRecursively(path); return true; } catch (Exception e) { throw new IOException(e); } } ZkDomain(ZooKeeperPlus zk, String path);  ZkDomain(ZooKeeperPlus zk, String path, boolean create, DomainMetadata initialMetadata); static ZkDomain create(ZooKeeperPlus zk,
                                String domainsRoot,
                                String domainName,
                                int numParts,
                                String storageEngineFactoryClassName,
                                String storageEngineOptions,
                                String partitionerClassName,
                                int id,
                                List<String> requiredHostFlags); void update(final int id,
                     final int numParts,
                     final String storageEngineFactoryClassName,
                     final String storageEngineOptions,
                     final String partitionerClassName,
                     final List<String> requiredHostFlags); @Override String getName(); @Override int getId(); @Override int getNumParts(); @Override Class<? extends StorageEngineFactory> getStorageEngineFactoryClass(); @Override String getStorageEngineFactoryClassName(); @Override StorageEngine getStorageEngine(); @Override Map<String, Object> getStorageEngineOptions(); @Override Partitioner getPartitioner(); @Override String getPartitionerClassName(); @Override List<String> getRequiredHostFlags(); @Override SortedSet<DomainVersion> getVersions(); @Override DomainVersion openNewVersion(DomainVersionProperties domainVersionProperties); @Override DomainVersion getVersion(int versionNumber); @Override DomainVersion getVersionShallow(int versionNumber); @Override boolean deleteVersion(int versionNumber); boolean delete(); @Override String toString();  }### Answer:
@Test public void testDelete() throws Exception { ZkDomain dc = ZkDomain.create(getZk(), getRoot(), "domain0", 1, ConstantStorageEngine.Factory.class.getName(), "---", Murmur64Partitioner.class.getName(), 0, Collections.<String>emptyList()); assertNotNull(getZk().exists(ZkPath.append(getRoot(), "domain0"), false)); assertTrue(dc.delete()); WaitUntil.orDie(() -> { try { return getZk().exists(ZkPath.append(getRoot(), "domain0"), false) == null; } catch (KeeperException e) { throw new RuntimeException(e); } catch (InterruptedException e) { throw new RuntimeException(e); } }); assertNull(getZk().exists(ZkPath.append(getRoot(), "domain0"), false)); }