From 08f2b317d60e44b8a4f94c77a96fe2bf48e990b8 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Lars=20K=C3=BChne?= Date: Sun, 17 Nov 2002 15:24:55 +0000 Subject: [PATCH] removed obsolete Global Property "require package html" and additional cleanup since that was the last boolean property --- .../tools/checkstyle/ConfigurationLoaderTest.java | 2 -- .../tools/checkstyle/ConfigurationTest.java | 15 +-------------- 2 files changed, 1 insertion(+), 16 deletions(-) diff --git a/src/tests/com/puppycrawl/tools/checkstyle/ConfigurationLoaderTest.java b/src/tests/com/puppycrawl/tools/checkstyle/ConfigurationLoaderTest.java index 38c673506..b7101ec0f 100644 --- a/src/tests/com/puppycrawl/tools/checkstyle/ConfigurationLoaderTest.java +++ b/src/tests/com/puppycrawl/tools/checkstyle/ConfigurationLoaderTest.java @@ -85,8 +85,6 @@ public class ConfigurationLoaderTest extends TestCase Configuration config = loadConfiguration("override_default_configuration.xml"); assertEquals("checkstyle.tab.width", 4, config.getTabWidth()); - assertTrue("checkstyle.require.packagehtml", - config.isRequirePackageHtml()); assertEquals("checkstyle.cache.file", config.getCacheFile(), "cache"); assertEquals("checkstyle.basedir", config.getBasedir(), "basedir"); assertEquals("checkstyle.locale.language", diff --git a/src/tests/com/puppycrawl/tools/checkstyle/ConfigurationTest.java b/src/tests/com/puppycrawl/tools/checkstyle/ConfigurationTest.java index 82b703d3d..a44efead0 100644 --- a/src/tests/com/puppycrawl/tools/checkstyle/ConfigurationTest.java +++ b/src/tests/com/puppycrawl/tools/checkstyle/ConfigurationTest.java @@ -24,7 +24,6 @@ public class ConfigurationTest mProps.setProperty(Defn.BASEDIR_PROP, BASEDIR); mProps.setProperty(Defn.CACHE_FILE_PROP, CACHE_FILE); mProps.setProperty(Defn.TAB_WIDTH_PROP, "" + TAB_WIDTH); - mProps.setProperty(Defn.REQUIRE_PACKAGE_HTML_PROP, "true"); mGlobalProps = new GlobalProperties(mProps, System.out); mConfig = new Configuration(mGlobalProps, new CheckConfiguration[0]); mConfig.setClassLoader(this.getClass().getClassLoader()); @@ -73,17 +72,10 @@ public class ConfigurationTest public void testGetProperties() { Properties props = mConfig.getProperties(); - int expectedSize = Defn.ALL_BOOLEAN_PROPS.length - + Defn.ALL_STRING_PROPS.length + int expectedSize = Defn.ALL_STRING_PROPS.length + Defn.ALL_INT_PROPS.length; assertEquals("size", expectedSize, props.size()); - for (int i = 0; i < Defn.ALL_BOOLEAN_PROPS.length; i++) { - final String key = Defn.ALL_BOOLEAN_PROPS[i]; - assertTrue("Missing property: " + key, - props.containsKey(key)); - } - for (int i = 0; i < Defn.ALL_INT_PROPS.length; i++) { final String key = Defn.ALL_INT_PROPS[i]; assertTrue("Missing property: " + key, @@ -101,9 +93,4 @@ public class ConfigurationTest { assertEquals(TAB_WIDTH, mConfig.getTabWidth()); } - - public void testIsRequirePackageHtml() - { - assertTrue(mConfig.isRequirePackageHtml()); - } }