From: Scott M S. <st...@us...> - 2004-03-13 18:29:00
|
User: starksm Date: 04/03/13 10:20:12 Modified: src/main/org/jboss/test/util/test Tag: Branch_3_2 PropertyEditorsUnitTestCase.java Log: Expand the java.util.Properties editor test for a properties string with ${x} references to other properties. Revision Changes Path No revision No revision 1.2.2.5 +13 -8 jbosstest/src/main/org/jboss/test/util/test/PropertyEditorsUnitTestCase.java Index: PropertyEditorsUnitTestCase.java =================================================================== RCS file: /cvsroot/jboss/jbosstest/src/main/org/jboss/test/util/test/PropertyEditorsUnitTestCase.java,v retrieving revision 1.2.2.4 retrieving revision 1.2.2.5 diff -u -r1.2.2.4 -r1.2.2.5 --- PropertyEditorsUnitTestCase.java 11 Feb 2004 02:54:06 -0000 1.2.2.4 +++ PropertyEditorsUnitTestCase.java 13 Mar 2004 18:20:12 -0000 1.2.2.5 @@ -23,7 +23,7 @@ @see org.jboss.util.propertyeditor.PropertyEditors @author Sco...@jb... -@version $Revision: 1.2.2.4 $ +@version $Revision: 1.2.2.5 $ **/ public class PropertyEditorsUnitTestCase extends JBossTestCase { @@ -144,7 +144,7 @@ // The input string data for each type String[][] inputData = { {"jboss.test:test=1"}, - {"prop1=value1\nprop2=value2"}, + {"prop1=value1\nprop2=value2\nprop3=value3\nprop32=${prop3}\nprop4=${user.home}"}, {"/tmp/test1", "/tmp/subdir/../test2"}, {"http://www.jboss.org"}, {"java.util.Arrays"}, @@ -157,6 +157,9 @@ Properties props = new Properties(); props.setProperty("prop1", "value1"); props.setProperty("prop2", "value2"); + props.setProperty("prop3", "value3"); + props.setProperty("prop32", "value3"); + props.setProperty("prop4", System.getProperty("user.home")); Object[][] expectedData = { {new ObjectName("jboss.test:test=1")}, {props}, @@ -210,12 +213,6 @@ } } - /** Override the testServerFound since these test don't need the JBoss server - */ - public void testServerFound() - { - } - /** Tests the DOM Document and Element editors. */ public void testDocumentElementEditors() @@ -239,4 +236,12 @@ assertTrue(ee.getValue() instanceof org.w3c.dom.Element); } + /** Override the testServerFound since these test don't need the JBoss server + */ + public void testServerFound() + { + } + public void initDelegate() + { + } } |