Author: rgoers
Date: Sun Apr 1 16:27:41 2012
New Revision: 1308148
URL: http://svn.apache.org/viewvc?rev=1308148&view=rev
Log:
Have testValidation and testValidation2 test something useful
Modified:
commons/proper/configuration/trunk/ (props changed)
commons/proper/configuration/trunk/src/test/java/org/apache/commons/configuration/TestVFSConfigurationBuilder.java
Propchange: commons/proper/configuration/trunk/
------------------------------------------------------------------------------
--- svn:ignore (original)
+++ svn:ignore Sun Apr 1 16:27:41 2012
@@ -1,16 +1,15 @@
-*~
+junit*.properties
*.iws
-*.ipr
-*.iml
-.*
+*~
docs
-target
+.*
+*.ipr
+*.ser
+STRING0
+lib
test-reports
+target
velocity.log*
maven.log
-STRING0
-lib
-*.ser
-junit*.properties
-*.patch
maven-eclipse.xml
+*.patch
Modified:
commons/proper/configuration/trunk/src/test/java/org/apache/commons/configuration/TestVFSConfigurationBuilder.java
URL:
http://svn.apache.org/viewvc/commons/proper/configuration/trunk/src/test/java/org/apache/commons/configuration/TestVFSConfigurationBuilder.java?rev=1308148&r1=1308147&r2=1308148&view=diff
==============================================================================
---
commons/proper/configuration/trunk/src/test/java/org/apache/commons/configuration/TestVFSConfigurationBuilder.java
(original)
+++
commons/proper/configuration/trunk/src/test/java/org/apache/commons/configuration/TestVFSConfigurationBuilder.java
Sun Apr 1 16:27:41 2012
@@ -877,8 +877,8 @@ public class TestVFSConfigurationBuilder
public void testValidation() throws Exception
{
factory.setFile(VALIDATION_FILE);
- factory.getConfiguration(true);
- String value = System.getProperty("key1");
+ CombinedConfiguration cc = factory.getConfiguration(true);
+ String value = cc.getString("key1");
assertNotNull("The test key was not located", value);
assertEquals("Incorrect value retrieved","value1",value);
}
@@ -887,8 +887,8 @@ public class TestVFSConfigurationBuilder
public void testValidation2() throws Exception
{
factory.setFile(VALIDATION2_FILE);
- factory.getConfiguration(true);
- String value = System.getProperty("key1");
+ CombinedConfiguration cc = factory.getConfiguration(true);
+ String value = cc.getString("key1");
assertNotNull("The test key was not located", value);
assertEquals("Incorrect value retrieved","value1",value);
}