Re: zope.testbrowser and WebTest (round 2)

Wichert Akkerman <[email protected]>
Newsgroups gmane.comp.web.zope.devel
Message-ID <[email protected]>
On 2011-1-31 07:02, Wolfgang Schnerring wrote:
> * Brian Sutherland<[email protected]>  [2011-01-30 16:04]:
>> I've finally finished refactoring my WebTest/testbrowser branches,
>> basically doing this:
>>
>>      - Integrate with WebTest. zope.testbrowser.webtest.Browser is a new
>>        Browser implementation that uses webtest.TestApp to drive a WSGI
>>        application. This allows simple and direct testing of WSGI applications.
>>
>>      - Re-write the test application as a pure WSGI application using WebOb.
>>        Run the existing tests using the WebTest based Browser
>>
>>      - Move zope.app.testing based Browser into zope.app.testing (leaving
>>        backwards compatibility imports in-place).
>>
>> This is a very big change, so I would appreciate anyone who would take a
>> look at these branches before I merge:
>
> Michael Howitz and I recently polished the integration of
> zope.testbrowser and wsgi_intercept to accomplish pretty much the same
> things you mentioned. (I'm aware that you two exchanged some emails
> about it, but don't know any details).
>
> So I'm curious: What are the differences bewteen WebTest and
> wsgi_intercept? Is one preferable to the other?

If I remember correctly WebTest wraps the WSGI app object directly and 
does not require monkeypatching urllib. To send requests to the app 
under testing you call WebTest post/get methods, which directly call the 
WSGI app.

Wichert.

-- 
Wichert Akkerman <[email protected]>   It is simple to make things.
http://www.wiggy.net/                  It is hard to make things simple.
_______________________________________________
Zope-Dev maillist  -  [email protected]
https://mail.zope.org/mailman/listinfo/zope-dev
**  No cross posts or HTML encoding!  **
(Related lists - 
 https://mail.zope.org/mailman/listinfo/zope-announce
 https://mail.zope.org/mailman/listinfo/zope )
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.