### Question:
ThrottleSettings { public static Policy parsePolicy(String policy) { if (Policy.NONE.toString().equalsIgnoreCase(policy)) return Policy.NONE; else if (Policy.IGNORE.toString().equalsIgnoreCase(policy)) return Policy.IGNORE; else if (Policy.ERROR.toString().equalsIgnoreCase(policy)) return Policy.ERROR; else if (Policy.BUFFER.toString().equalsIgnoreCase(policy)) return Policy.BUFFER; else if (Policy.CONFLATE.toString().equalsIgnoreCase(policy)) return Policy.CONFLATE; ConfigurationException ex = new ConfigurationException(); throw ex; } ThrottleSettings(); static Policy parsePolicy(String policy); boolean isClientThrottleEnabled(); boolean isInboundClientThrottleEnabled(); boolean isOutboundClientThrottleEnabled(); boolean isDestinationThrottleEnabled(); boolean isInboundDestinationThrottleEnabled(); boolean isOutboundDestinationThrottleEnabled(); Policy getInboundPolicy(); void setInboundPolicy(Policy inPolicy); Policy getOutboundPolicy(); void setOutboundPolicy(Policy outPolicy); String getDestinationName(); void setDestinationName(String destinationName); int getIncomingClientFrequency(); void setIncomingClientFrequency(int n); int getIncomingDestinationFrequency(); void setIncomingDestinationFrequency(int n); int getOutgoingClientFrequency(); void setOutgoingClientFrequency(int n); int getOutgoingDestinationFrequency(); void setOutgoingDestinationFrequency(int n); static final String ELEMENT_INBOUND; static final String ELEMENT_OUTBOUND; static final String ELEMENT_POLICY; static final String ELEMENT_DEST_FREQ; static final String ELEMENT_CLIENT_FREQ; }### Answer:
@Test public void testUnknownPolicy() { try { ThrottleSettings.parsePolicy("UNKNOWN"); } catch (ConfigurationException ce) { } catch (Exception e) { Assert.fail(UNEXPECTED_EXCEPTION_STRING + e); } }