commons-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From rdon...@apache.org
Subject cvs commit: jakarta-commons/digester/src/test/org/apache/commons/digester BeanPropertySetterRuleTestCase.java
Date Wed, 17 Jul 2002 16:53:50 GMT
rdonkin     2002/07/17 09:53:50

  Modified:    digester/src/test/org/apache/commons/digester
                        BeanPropertySetterRuleTestCase.java
  Log:
  Changed from depricated StringBufferInputStream to StringReader. Patch submitted by Mike
Flester.
  
  Revision  Changes    Path
  1.6       +8 -7      jakarta-commons/digester/src/test/org/apache/commons/digester/BeanPropertySetterRuleTestCase.java
  
  Index: BeanPropertySetterRuleTestCase.java
  ===================================================================
  RCS file: /home/cvs/jakarta-commons/digester/src/test/org/apache/commons/digester/BeanPropertySetterRuleTestCase.java,v
  retrieving revision 1.5
  retrieving revision 1.6
  diff -u -r1.5 -r1.6
  --- BeanPropertySetterRuleTestCase.java	23 Mar 2002 17:45:59 -0000	1.5
  +++ BeanPropertySetterRuleTestCase.java	17 Jul 2002 16:53:50 -0000	1.6
  @@ -61,7 +61,8 @@
   
   import java.io.IOException;
   import java.io.InputStream;
  -import java.io.StringBufferInputStream;
  +import java.io.Reader;
  +import java.io.StringReader;
   import java.util.ArrayList;
   import java.util.List;
   
  @@ -173,7 +174,7 @@
   
   
           try {
  -            digester.parse(xmlTestStream());
  +            digester.parse(xmlTestReader());
   
           } catch (Throwable t) {
               fail("Exception prevented test execution: " + t);
  @@ -264,7 +265,7 @@
           digester.addRule("root/gamma", gammaRule);
   
           try {
  -            digester.parse(xmlTestStream());
  +            digester.parse(xmlTestReader());
   
           } catch (Throwable t) {
               fail("Exception prevented test execution: " + t);
  @@ -315,7 +316,7 @@
   
           SimpleTestBean bean = null;
           try {
  -            bean = (SimpleTestBean) digester.parse(xmlTestStream());
  +            bean = (SimpleTestBean) digester.parse(xmlTestReader());
   
           } catch (Throwable t) {
               fail("Exception prevented test execution: " + t);
  @@ -356,7 +357,7 @@
   
           SimpleTestBean bean = null;
           try {
  -            bean = (SimpleTestBean) digester.parse(xmlTestStream());
  +            bean = (SimpleTestBean) digester.parse(xmlTestReader());
   
           } catch (Throwable t) {
               fail("Exception prevented test execution: " + t);
  @@ -385,8 +386,8 @@
       /**
        * Get input stream from {@link #TEST_XML}.
        */
  -    private InputStream xmlTestStream() throws IOException {
  -        return new StringBufferInputStream(TEST_XML);
  +    private Reader xmlTestReader() throws IOException {
  +        return new StringReader(TEST_XML);
       }
   
   }
  
  
  

--
To unsubscribe, e-mail:   <mailto:commons-dev-unsubscribe@jakarta.apache.org>
For additional commands, e-mail: <mailto:commons-dev-help@jakarta.apache.org>


Mime
View raw message