gcasper     2003/09/19 04:41:49

  Added:       src/blocks/webdav/test/anteater step3.xml
  Log:
  Added Anteater test
  
  Revision  Changes    Path
  1.1                  cocoon-2.1/src/blocks/webdav/test/anteater/step3.xml
  
  Index: step3.xml
  ===================================================================
  <?xml version="1.0" encoding="utf-8"?>
  
  <project name="webdav-test" default="webdav-step3">
  
    <group id="default">
      <property name="usetidy" value="true"/>
    </group>
  
    <target name="webdav-step3">
      <property name="samples" value="${cocoon}/samples/webdav"/>
  
      <!-- testing basic TraversableGenerator functionality -->
      <httpRequest href="${samples}/step1/repo/"
                   useTidy="false"
                   description="Test the 'step1' sample">
        <namespace prefix="collection" 
uri="http://apache.org/cocoon/collection/1.0"/>
        <match>
          <xpath select="/collection:collection/collection:resource/@name" 
value="contentA.xml"/>
        </match>
      </httpRequest>
  
      <!-- check contents of contentB.xml -->
      <httpRequest href="${samples}/step3/repo/dir2/contentB.xml"
                   description="Test the 'step3' sample">
        <match>
          <xpath select="/html/body/form/p/[EMAIL PROTECTED]'title']/@value" 
pattern="Content B"/>
          <xpath select="/html/body/form/p/textarea" pattern="First Paragraph"/>
          <xpath select="/html/body/form/p/textarea" pattern="Second 
Paragraph"/>
          <xpath select="/html/body/form/@action" assign="action"/>
        </match>
      </httpRequest>
  
      <!-- change contents of contentB.xml -->
      <httpRequest href="${cocoon}${action}"
                   useTidy="false"
                   description="Test the 'step3' sample">
        <parameter name="title" value="Title B"/>
        <parameter name="para" value="test2"/>
        <parameter name="para" value="test2"/>
        <match>
          <xpath select="/page/sourceResult/execution" value="success"/>
        </match>
      </httpRequest>
  
      <!-- check changes -->
      <httpRequest href="${samples}/step3/repo/dir2/contentB.xml"
                   description="Test the 'step3' sample">
        <match>
          <xpath select="/html/body/form/p/[EMAIL PROTECTED]'title']/@value" 
pattern="Title B"/>
          <xpath select="/html/body/form/p/textarea" pattern="test2"/>
          <xpath select="/html/body/form/@action" assign="action"/>
        </match>
      </httpRequest>
  
      <!-- undo changes -->
      <httpRequest href="${cocoon}${action}"
                   useTidy="false"
                   description="Test the 'step3' sample">
        <parameter name="title" value="Content B"/>
        <parameter name="para" value="First Paragraph"/>
        <parameter name="para" value="Second Paragraph"/>
        <match>
          <xpath select="/page/sourceResult/execution" value="success"/>
        </match>
      </httpRequest>
  
      <!-- check success of undo -->
      <httpRequest href="${samples}/step3/repo/dir2/contentB.xml"
                   description="Test the 'step3' sample">
        <match>
          <xpath select="/html/body/form/p/[EMAIL PROTECTED]'title']/@value" 
pattern="Content B"/>
          <xpath select="/html/body/form/p/textarea" pattern="First Paragraph"/>
          <xpath select="/html/body/form/p/textarea" pattern="Second 
Paragraph"/>
          <xpath select="/html/body/form/@action" assign="action"/>
        </match>
      </httpRequest>
    </target>
  </project>
  
  
  

Reply via email to