com.netriser.xmltestsuite.testcases
Class fetch

java.lang.Object
  |
  +--junit.framework.Assert
        |
        +--junit.framework.TestCase
              |
              +--com.netriser.xmltestsuite.testcases.XmlTestCase
                    |
                    +--com.netriser.xmltestsuite.testcases.fetch
All Implemented Interfaces:
junit.framework.Test, XmlElement

public class fetch
extends XmlTestCase

XmlTestCase that fetches a web page. The url can be specified either

Variable substitution is performed before the fetch. Otherwise the fetch fails if a 400 OK is not received. Http redirections occur automatically.

To test the content of the response use in conjunction with verify and <definePage>

To verify the links recursively use in conjunction with verifylinks

 		<fetch url="http://..."/>
 		<verifylinks depth="2" onsiteonly="true"/>

The fetch construct can be used with urls of the form http, file and ftp. It can be used to fetch with the https protocol if java has been correctly configured.

Author:
david

Constructor Summary
fetch(java.lang.String fName)
           
 
Method Summary
 void setLink(java.lang.String s)
           
 void setQuerystring(java.lang.String s)
           
 void setUrl(java.lang.String s)
          set Url.
 
Methods inherited from class com.netriser.xmltestsuite.testcases.XmlTestCase
getElementList, getXmlElement, setForm, setFrame, setFrameName, setHtmlWarnings, setPage, setPageElement, setStepid, setWindowName, setXmlElement
 
Methods inherited from class junit.framework.TestCase
countTestCases, getName, run, run, runBare, setName, toString
 
Methods inherited from class junit.framework.Assert
assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertFalse, assertFalse, assertNotNull, assertNotNull, assertNotSame, assertNotSame, assertNull, assertNull, assertSame, assertSame, assertTrue, assertTrue, fail, fail
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

fetch

public fetch(java.lang.String fName)
See Also:
TestCase.TestCase(String)
Method Detail

setQuerystring

public void setQuerystring(java.lang.String s)

setLink

public void setLink(java.lang.String s)

setUrl

public void setUrl(java.lang.String s)
set Url.