XenonConfiguration { public static boolean bool(String subsystem, String property, boolean defaultValue) { return INSTANCE.getBool(subsystem, property, defaultValue); } XenonConfiguration(ConfigurationSource source); static double decimal(Class<?> subsystem, String property, double defaultValue); static long number(Class<?> subsystem, String property, long defaultValue); static int integer(Class<?> subsystem, String property, long defaultValue); static long duration(Class<?> subsystem, String property, Duration defaultValue); static long duration(Class<?> subsystem, String property, TimeUnit unit, long duration); static String string(Class<?> subsystem, String property, String defaultValue); static T choice(Class<?> subsystem, String property, Class<T> enumType,
            T defaultValue); static String secret(Class<?> subsystem, String property, String defaultValue); static boolean bool(String subsystem, String property, boolean defaultValue); static boolean bool(Class<?> subsystem, String property, boolean defaultValue);  }
@Test public void bool() throws Exception { prepareConfig("true"); assertEquals(true, this.config.getBool(XenonConfigurationTest.class, this.foundProperty, false)); assertEquals(false, this.config.getBool(XenonConfigurationTest.class, this.undefined, false)); assertEquals(true, this.config.getBool(XenonConfigurationTest.class, this.undefined, true)); prepareConfig("1"); assertEquals(true, this.config.getBool(XenonConfigurationTest.class, this.foundProperty, false)); prepareConfig("0"); assertEquals(false, this.config.getBool(XenonConfigurationTest.class, this.foundProperty, true)); }