### Question:
DefaultConfigurator implements Configuration<Map<String, Object>> { @SuppressWarnings("unchecked") @Override public <T> T getParameter(final String name, final T defaultValue) { if (parameters == null) { throw new IllegalStateException(MessageCatalog._00030_INVALID_CONFIGURATION_STATE); } T value = (T) parameters.get(name); return value != null ? value : defaultValue; }  @Override void configure(final Configurable configurable); @SuppressWarnings("unchecked") @Override T getParameter(final String name, final T defaultValue); static final String CONFIGURATION_FILE_SYSTEM_PROPERTY; static final String ETC_DIR_SYSTEM_PROPERTY; static final String CONFIGURATION_FILENAME; static final String DEFAULT_CONFIGURATION_FILE_NAME; }### Answer:
@Test public void callInInvalidState() { try { cut.getParameter(randomString(), randomString()); fail(); } catch (final IllegalStateException expected) { } }