Re: Dealing with 'external' resources and Global configuration

Russell Gold <[email protected]>
Newsgroups gmane.comp.web.httpunit.devel
Message-ID <[email protected]>
On Apr 3, 2008, at 10:24 AM, Tim Diggins wrote:

> == Dealing with 'external' resources and Global configuration ==
>
> Background (please correct me if this is wrong):
> httpunit effectively consists of a pseudoclient and a pseudoserver -
> which itself can be act as a servlet container (like Tomcat/Jetty)

HttpUnit actually consists of three parts: a web-agent (HttpUnit)  
which interacts with a web server across a network connection, a  
container (ServletUnit) which combines an implementation of the  
servlet spec with a built-in client and uses no network access, and a  
server (PseudoServer) which can simulate a web server in order to test  
web-agents.
>

> At present external (outside the pseudoserver) resources cannot be
> fetched by the pseudoclient in http-unit. At present resources that
> are external (e.g. <script href="http://adsense.google.com/
> blahblahblah" /> ) httpunit just tries to fetch the same path (/
> blahblahblah) from the pseudoserver - which fails, with an error
> (providing the resource is automatically retrieved, as for scriptable
> objects.

During HttpUnit's own regression suite, PseudoServer acts as a web  
server using the network capabilities of the local box. This means  
that no external connectivity is required; however, that just means  
that the host name to which HttpUnit connects is "localhost." If  
another host name is supplied, HttpUnit will access an external  
resource.

I have no idea why there should be any special handling needed for  
"external" resources. HttpUnit cannot tell where its server is. It  
simply asks the VM/OS to connect to a named host.

>

-------------------------------------------------------------------------
Check out the new SourceForge.net Marketplace.
It's the best place to buy or sell services for
just about anything Open Source.
http://ad.doubleclick.net/clk;164216239;13503038;w?http://sf.net/marketplace

_______________________________________________
Httpunit-develop mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/httpunit-develop
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.