commons-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From sand...@apache.org
Subject cvs commit: jakarta-commons/digester/src/test/org/apache/commons/digester/xmlrules test.xml testCircularRules.xml testrules.xml testrulesinclude.xml
Date Tue, 04 Dec 2001 19:48:22 GMT
sanders     01/12/04 11:48:22

  Added:       digester/src/test/org/apache/commons/digester/xmlrules
                        test.xml testCircularRules.xml testrules.xml
                        testrulesinclude.xml
  Log:
  Tests First :)
  
  XML Rules definition
  Graciously submitted by Dave Martin [dmartin@altoweb.com]
  
  Revision  Changes    Path
  1.1                  jakarta-commons/digester/src/test/org/apache/commons/digester/xmlrules/test.xml
  
  Index: test.xml
  ===================================================================
  <!-- Input data to test the DigesterLoader -->
  <root>
    <foo value="foo1">
      <baz  value="baz1"/>
      <bar>
        <foo value="foo2"/>
      </bar>
    </foo>
    <baz value="baz2"/>
    <foo value="foo3">
      <bar>
  	  <baz value="baz3"/>
        <foo value="foo4"/>
      </bar>
    </foo>
  </root>
  
  
  
  1.1                  jakarta-commons/digester/src/test/org/apache/commons/digester/xmlrules/testCircularRules.xml
  
  Index: testCircularRules.xml
  ===================================================================
  <?xml version="1.0"?>
  
  <!-- Rules to test the DigesterLoader's circular include detection. 
       Attempting to create a digester with these rules should result
       in an exception. -->
       
  <digester-rules>
    <pattern value="root/foo">
      <object-create-rule classname="org.apache.commons.digester.xmlrules.TestObject"/>
      <set-next-rule methodname="add" paramtype="java.lang.Object"/>
  	  <set-properties-rule/>
  	  <include path="org/apache/commons/digester/xmlrules/testCircularRules.xml"/>
    </pattern>
  </digester-rules>
  
  
  
  1.1                  jakarta-commons/digester/src/test/org/apache/commons/digester/xmlrules/testrules.xml
  
  Index: testrules.xml
  ===================================================================
  <?xml version="1.0"?>
  <digester-rules>
    <pattern value="root/foo">
      <object-create-rule classname="org.apache.commons.digester.xmlrules.TestObject"/>
      <set-next-rule methodname="add" paramtype="java.lang.Object"/>
  	  <set-properties-rule/>
  	  <include path="org/apache/commons/digester/xmlrules/testrulesinclude.xml"/>
      <include class="org.apache.commons.digester.xmlrules.TestDigesterRulesSource"/>
    </pattern>
  </digester-rules>
  
  
  
  1.1                  jakarta-commons/digester/src/test/org/apache/commons/digester/xmlrules/testrulesinclude.xml
  
  Index: testrulesinclude.xml
  ===================================================================
  <?xml version="1.0"?>
  <digester-rules>
    <pattern value = "bar">
      <pattern value="foo">
        <object-create-rule classname="org.apache.commons.digester.xmlrules.TestObject"/>
        <set-next-rule methodname="add" paramtype="java.lang.Object"/>
  	    <set-properties-rule/>
      </pattern>
    </pattern>
  </digester-rules>
  
  
  

--
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