NinjaPropertiesImpl implements NinjaProperties { @Override public Boolean getBooleanOrDie(String key) { Boolean value = getBoolean(key); if (value == null) { logger.error(String.format(ERROR_KEY_NOT_FOUND, key)); throw new RuntimeException(String.format(ERROR_KEY_NOT_FOUND, key)); } else { return value; } } NinjaPropertiesImpl(
            NinjaMode ninjaMode);  NinjaPropertiesImpl(
            NinjaMode ninjaMode, String externalConfigurationPath); @Override String get(String key); @Override String getOrDie(String key); @Override Integer getInteger(String key); @Override Integer getIntegerOrDie(String key); @Override Boolean getBooleanOrDie(String key); @Override Boolean getBoolean(String key); void setProperty(String key, String value); void bindProperties(Binder binder); @Override boolean isProd(); @Override boolean isDev(); @Override boolean isTest(); @Override String getContextPath(); @Override void setContextPath(String contextPath); @Override Properties getAllCurrentNinjaProperties(); @Override String[] getStringArray(String key); @Override String getWithDefault(String key, String defaultValue); @Override Integer getIntegerWithDefault(String key, Integer defaultValue); @Override Boolean getBooleanWithDefault(String key, Boolean defaultValue);  }
@Test(expected = RuntimeException.class) public void testGetBooleanOrDie() { NinjaPropertiesImpl ninjaPropertiesImpl = new NinjaPropertiesImpl(NinjaMode.dev); assertEquals(true, ninjaPropertiesImpl.getBooleanOrDie("booleanTestTrue")); ninjaPropertiesImpl.getBooleanOrDie("booleanNotValid"); }