package edu.duke.cabig.c3pr.infrastructure;


import edu.duke.cabig.c3pr.tools.Configuration;
import gov.nih.nci.cabig.ctms.tools.configuration.ConfigurationProperties;
import gov.nih.nci.cabig.ctms.tools.configuration.ConfigurationProperty;
import junit.framework.TestCase;

/**
 * @author Ramakrishna
 */
public class ConfigurationPropertiesTest extends TestCase {
    public void testEmptyPropertiesIsEmptyWithoutErrors() throws Exception {
        ConfigurationProperties empty = ConfigurationProperties.empty();
        assertEquals(0, empty.size());
        assertNull(empty.get("anything"));
        assertNull(empty.getNameFor("anything"));
    }
    
    public void testGetCoppaEnableProperty() throws Exception {
    	ConfigurationProperty coppaEnable = Configuration.COPPA_ENABLE;
    	assertNotNull("Missing the property 'COPPA_ENABLE'",coppaEnable);
      //  assertTrue("COPPA_ENABLE should have been true", Boolean.parseBoolean(coppaEnable.getDefault().toString()));
    }
}

@@ -982,10 +982,211 @@
 ;%0A    %7D%0A
+    %0A    public void testGetProperties() throws Exception %7B%0A    %09Configuration conf = new Configuration();%0A    %09assertEquals(%22Property count should be 35%22, 35, conf.getProperties().size());%0A    %7D%0A    %0A
 %7D%0A

Test case coverage