### Question:
DiscoveredServerPropertiesCache { public void deleteCachedProperty(final String host, final String zoneName, final String propertyName) { if (host == null || host.isEmpty()) { throw new IllegalArgumentException("null or empty host"); } String myZone = zoneName; if (zoneName == null) { myZone = ""; } if (propertyName == null || propertyName.isEmpty()) { throw new IllegalArgumentException("null or empty property name"); } Map<String, String> zoneCache = getCacheForHostAndZone(host, myZone); if (zoneCache != null) { zoneCache.remove(propertyName); } } DiscoveredServerPropertiesCache(); IRODSServerProperties retrieveIRODSServerProperties(final String host, final String zoneName); ClientHints retrieveClientHints(final String host, final String zoneName); String retrieveValue(final String host, final String zoneName, final String propertyName); void deleteCachedClientHints(final String host, final String zoneName); void deleteCachedIRODSServerProperties(final String host, final String zoneName, final String propertyName); void deleteCachedProperty(final String host, final String zoneName, final String propertyName); void deleteCache(final String host, final String zoneName); void cacheClientHints(final String host, final String zoneName, final ClientHints clientHints); void cacheIRODSServerProperties(final String host, final String zoneName,
			final IRODSServerProperties irodsServerProperties); void cacheAProperty(final String host, final String zoneName, final String propertyName,
			final String value); static final Logger log; static final String JARGON_SPECIFIC_QUERIES_SUPPORTED; static final String STRICT_ACLS; static final String EIRODS; static final String RULE_BASE; static final String CHECKSUM_TYPE; static final String IS_TRUE; static final String IS_FALSE; }### Answer:
@Test public void testDeleteCachedProperty() { String testHost = "host1"; String testZone = "zone1"; String testKey = "key1"; String testValue = "value1"; DiscoveredServerPropertiesCache target = new DiscoveredServerPropertiesCache(); target.cacheAProperty(testHost, testZone, testKey, testValue); target.deleteCachedProperty(testHost, testZone, testKey); String val = target.retrieveValue(testHost, testZone, testKey); Assert.assertNull(val); }
@Test(expected = IllegalArgumentException.class) public void testDeleteCachedPropertyNullHost() { String testHost = null; String testZone = "zone1"; String testKey = "key1"; DiscoveredServerPropertiesCache target = new DiscoveredServerPropertiesCache(); target.deleteCachedProperty(testHost, testZone, testKey); }
@Test(expected = IllegalArgumentException.class) public void testDeleteCachedPropertyBlankHost() { String testHost = ""; String testZone = "zone1"; String testKey = "key1"; DiscoveredServerPropertiesCache target = new DiscoveredServerPropertiesCache(); target.deleteCachedProperty(testHost, testZone, testKey); }
@Test public void testDeleteCachedPropertyNullZone() { String testHost = "host"; String testZone = null; String testKey = "key1"; DiscoveredServerPropertiesCache target = new DiscoveredServerPropertiesCache(); target.deleteCachedProperty(testHost, testZone, testKey); }
@Test public void testDeleteCachedPropertyBlankZone() { String testHost = "host"; String testZone = ""; String testKey = "key1"; DiscoveredServerPropertiesCache target = new DiscoveredServerPropertiesCache(); target.deleteCachedProperty(testHost, testZone, testKey); }
@Test(expected = IllegalArgumentException.class) public void testDeleteCachedPropertyNullKey() { String testHost = "host"; String testZone = "zone"; String testKey = null; DiscoveredServerPropertiesCache target = new DiscoveredServerPropertiesCache(); target.deleteCachedProperty(testHost, testZone, testKey); }
@Test(expected = IllegalArgumentException.class) public void testDeleteCachedPropertyBlankKey() { String testHost = "host"; String testZone = "zone"; String testKey = ""; DiscoveredServerPropertiesCache target = new DiscoveredServerPropertiesCache(); target.deleteCachedProperty(testHost, testZone, testKey); }