juergen     2002/06/18 23:52:34

  Added:       
testsuite/testsuite/junit/xmltestcases/DASL/functional/where/DAVResourceType
                        NonExistingProperty.xml LiveAndDeadProperty.xml
  Log:
  Testcases to check the 'where' element, on DAV Properties, within DASL Basic Search.
  
  Revision  Changes    Path
  1.1                  
jakarta-slide/testsuite/testsuite/junit/xmltestcases/DASL/functional/where/DAVResourceType/NonExistingProperty.xml
  
  Index: NonExistingProperty.xml
  ===================================================================
  <?xml version="1.0" encoding="UTF-8"?>
  <!DOCTYPE test SYSTEM "../../../../../Tprocessor.dtd">
  
  <test>
        <specification>
                
                <abstract> A nonexistent propery is searched for. </abstract>
                
                <pre-Requisite>A collection has been created and defined in 
tprocessor.cmd.</pre-Requisite>
                
                <description>
                1) A Search is performed against globalVariableCollection for a 
property that doesn't exist.
                </description>
                
                <expectedResult>The Search should return a 207 Multi-Status response. 
Inside the body should be a 200 OK
                response code indicating the HREF was found. A 404 Not Found error 
should also be returned as the property could
                not be found on the specified resource.
                </expectedResult>
                
        </specification>
        
        
        <step> 
                <request>
                        <command varUsage ="globalVariableServerName">SEARCH 
/%globalVariableServerName% HTTP/1.1</command>
                        <body varUsage="globalVariableCollection"><![CDATA[<?xml 
version="1.0" encoding="UTF-8"?>
                                                        <searchrequest xmlns:D="DAV:">
                                                                <D:basicsearch>
                                                                        <D:select>
                                                                                
<D:prop>
                                                                                       
 <D:undefinedproperty/>
                                                                                
</D:prop>
                                                                        </D:select>
                                                                        <D:from>
                                                                                
<D:scope>
                                                                                       
 <D:href>%globalVariableCollection%/</D:href>
                                                                                       
 <D:depth>1</D:depth>
                                                                                
</D:scope>
                                                                        </D:from>
                                                                </D:basicsearch>
                                                        </searchrequest>        
                                        ]]>                     
                                </body>
                </request>
        
                <response>
                        <command>HTTP/1.0 207 Multi-Status</command>
                        <body 
varUsage="globalVariableServerName,globalVariableCollection"><![CDATA[<?xml 
version="1.0" encoding="UTF-8"?>
                                                        <D:multistatus xmlns:D="DAV:">
                                                                <D:response>
                                                                
<D:href>/%globalVariableServerName%/%globalVariableCollection%</D:href>
                                                                        <D:propstat>
                                                                                
<D:prop />
                                                                                
<D:status>HTTP/1.1 200 OK</D:status>
                                                                        </D:propstat>
                                                                        <D:propstat>
                                                                                
<D:prop>
                                                                                       
 <D:undefinedproperty />
                                                                                
</D:prop>
                                                                                
<D:status>HTTP/1.1 404 Not Found</D:status>
                                                                        </D:propstat>
                                                                </D:response>
                                                        </D:multistatus>
                                ]]>
                        </body>
                </response>
        </step> 
        
        
  </test>
  
  
  
  1.1                  
jakarta-slide/testsuite/testsuite/junit/xmltestcases/DASL/functional/where/DAVResourceType/LiveAndDeadProperty.xml
  
  Index: LiveAndDeadProperty.xml
  ===================================================================
  <?xml version="1.0" encoding="UTF-8"?>
  <!DOCTYPE test SYSTEM "../../../../../Tprocessor.dtd">
  
  <test> 
  
  
        <specification>
  
                <abstract> Search for both live and dead properties. </abstract>
  
                <pre-Requisite>A collection has been created and defined in 
tprocessor.cmd.</pre-Requisite>
  
                <description>
                1) Put to create a resource to be PropPatched.
                2) PropPatch to create a dead property to be searched for.
                3) PropFind to check properties exists.
                4) Search to find values of both the live and dead properties.
                5) Delete the created resource.
                </description>
  
                <expectedResult>A Multi-Status 207 response code should be returned by 
the Search.
                All requested properties should be discovered.</expectedResult>
  
        </specification>
  
  
  
  
        <step> 
                <request>
                        <command varUsage 
="userNumber,globalVariableCollection,globalVariableServerName">PUT 
/%globalVariableServerName%/%globalVariableCollection%/test.xml HTTP/1.1</command>
                        <header>Accept-Language: en-us</header>
                        <header>Translate: f</header>
                        <header>User-Agent: Microsoft Data Access Internet Publishing 
Provider DAV</header>
                        <header>Connection: Keep-Alive</header>
    
                        <body 
fileReference="../../../../contentDirectory/validXML.xm1">
                        </body>
                </request>
                
                <response>
                        <command>HTTP/1.0 201 Created</command>
                        <header>Date: Mon, 12 Mar 2001 17:21:35 GMT+01:00</header>
                        <header>Content-Language: en</header>
                        <header>Servlet-Engine: Tomcat Web Server/3.2 beta 4 (JSP 1.1; 
Servlet 2.2; Java 1.3.0; Windows NT 4.0 x86; java.vendor=Sun Microsystems 
Inc.)</header>
                </response>     
        </step>
        
        
        <step>
                <request>
                        <command 
varUsage="globalVariableCollection,globalVariableServerName">PROPPATCH 
/%globalVariableServerName%/%globalVariableCollection%/test.xml HTTP/1.1</command>
                        <header>Content-Type: text/xml</header>
                        <header>User-Agent: Microsoft Data Access Internet Publishing 
Provider DAV</header>
                        <header>Accept-Language: en-us</header>
                        <header>Translate: f</header>
                        <header>Pragma: no-cache</header>
                        <header>Connection: close</header>
                        <body><![CDATA[<?xml version="1.0" encoding="utf-8" ?>
                        <D:propertyupdate xmlns:D="DAV:" xmlns:R="http://www.com/";>
                                <D:set>
                                        <D:prop>
                                                <D:test>test</D:test>
                                        </D:prop>
                                </D:set>
                        </D:propertyupdate>
                        ]]></body>
                </request>
                <response>
                        <command>HTTP/1.0 207 Multi-Status</command>
                        <header>Date: Tue, 13 Feb 2001 12:45:26 GMT+01:00</header>
                        <header>Content-Language: en</header>
                        <header>Servlet-Engine: Tomcat Web Server/3.2 beta 4 (JSP 1.1; 
Servlet 2.2; Java 1.3.0; Windows NT 4.0 x86; java.vendor=Sun Microsystems 
Inc.)</header>
                        <body 
varUsage="globalVariableCollection,userNumber,globalVariableServerName"><![CDATA[<?xml 
version="1.0" encoding="utf-8" ?>
                                <d:multistatus xmlns:d="DAV">
                                        <d:response>
                                                
<d:href>/%globalVariableServerName%/%globalVariableCollection%/test.xml</d:href>
                                                <d:propstat>
                                                        <d:prop>
                                                                <D:test 
xmlns:D="DAV:"/>
                                                        </d:prop>
                                                                <d:status>HTTP/1.1 200 
OK</d:status>
                                                </d:propstat>
                                        </d:response>
                                </d:multistatus>
                                ]]>
                        </body>
                </response>
        </step>
        
        
        
        
        <step>
              <request>
                 <command 
varUsage="globalVariableCollection,globalVariableServerName">PROPFIND 
/%globalVariableServerName%/%globalVariableCollection%/test.xml HTTP/1.1</command>
                 <header>Accept-Language: en-us</header>
                 <header>Content-Type: text/xml</header>
                 <header>Translate: f</header>
                 <header>Depth: 1</header>
                 <header>User-Agent: Microsoft Data Access Internet Publishing 
Provider DAV</header>
                 <header>Connection: Keep-Alive</header>
                 <body><![CDATA[<?xml version="1.0"?>
                                <D:propfind xmlns:D="DAV:">
                                        <D:prop>
                                                <D:test/>
                                                <D:displayname/>
                                        </D:prop>
                                </D:propfind>]]>
                </body>
              </request>
              <response>
                 <command>HTTP/1.0 207 Multi-Status</command>
                 <header>Servlet-Engine: Tomcat Web Server/3.2.1 (JSP 1.1; Servlet 
2.2; Java 1.3.0_02; Windows NT 4.0 x86; java.vendor=Sun Microsystems Inc.)</header>
                 <body 
varUsage="globalVariableCollection,globalVariableServerName"><![CDATA[<multistatus 
xmlns="DAV:">
                                                <response>
                                                        
<href>/%globalVariableServerName%/%globalVariableCollection%/test.xml</href>
                                                                <propstat>
                                                                        <prop>
                                                                                
<test>test</test>
                                                                                
<displayname>test.xml</displayname>
                                                                        </prop>
                                                                        
<status>HTTP/1.1 200 OK</status>
                                                                </propstat>
                                                </response>
                                        </multistatus>
                                                ]]>
                 </body>
              </response>
         </step>
         
         
                 
         
         
        <step> 
                <request>
                        <command varUsage 
="globalVariableServerName,globalVariableCollection">SEARCH 
/%globalVariableServerName%/%globalVariableCollection% HTTP/1.1</command>
                        <body><![CDATA[<?xml version="1.0" encoding="UTF-8"?>
                                                        <searchrequest xmlns:D="DAV:">
                                                                <D:basicsearch>
                                                                        <D:select>
                                                                                
<D:prop>
                                                                                       
 <D:displayname/>
                                                                                       
 <D:getcontenttype/>
                                                                                       
 <D:test/>
                                                                                
</D:prop>
                                                                        </D:select>
                                                                        <D:from>
                                                                                
<D:scope>
                                                                                       
 <D:href>test.xml/</D:href>
                                                                                       
 <D:depth>0</D:depth>
                                                                                
</D:scope>
                                                                        </D:from>
                                                                </D:basicsearch>
                                                        </searchrequest>               
 
                                        ]]>                     
                                </body>
                </request>
        
                <response>
                        <command>HTTP/1.0 207 Multi-Status</command>
                        <body 
varUsage="globalVariableServerName,globalVariableCollection"><![CDATA[<?xml 
version="1.0" encoding="UTF-8"?>
                                                <D:multistatus xmlns:D="DAV:">
                                                        <D:response>
                                                                
<D:href>/%globalVariableServerName%/%globalVariableCollection%/test.xml</D:href>
                                                                <propstat xmlns="DAV:">
                                                                        <prop>
                                                                                
<displayname>test.xml</displayname>
                                                                                
<getcontenttype>text/xml</getcontenttype>
                                                                                
<test>test</test>
                                                                        </prop>
                                                                        
<status>HTTP/1.1 200 OK</status>
                                                                </propstat>
                                                        </D:response>
                                                </D:multistatus>
                                ]]>
                        </body>
                </response>
        </step>
        
  <cleanup>
        
   <step>
       <request>
        <command varUsage="globalVariableCollection,globalVariableServerName"> DELETE 
/%globalVariableServerName%/%globalVariableCollection%/test.xml HTTP/1.1</command>
           <header>Accept-Language: en-us</header>
           <header>Destroy: NoUndelete</header>
           <header>Translate: f</header>
           <header>User-Agent: Microsoft Data Access Internet Publishing Provider 
DAV</header>
           <header>Connection: Keep-Alive</header>
        </request>
        
        <response>
           <command>HTTP/1.0 204 No Content</command>
           <header>Date: Wed, 14 Mar 2001 14:47:37 GMT+01:00</header>
           <header>Content-Language: en</header>
           <header>Servlet-Engine: Tomcat Web Server/3.2 beta 4 (JSP 1.1; Servlet 2.2; 
Java 1.3.0; Windows NT 4.0 x86; java.vendor=Sun Microsystems Inc.)</header>
        </response>
      </step>
        
  </cleanup>
        
        
        
        
        
  </test>
  
  

--
To unsubscribe, e-mail:   <mailto:[EMAIL PROTECTED]>
For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>

Reply via email to