[Zope3-dev] Re: XPATH in zope.testbrowser, assertions in zope.testrecorder

Benji York benji at zope.com
Sat Jun 24 21:40:50 EDT 2006


Martin Aspeli wrote:
> Benji York wrote:
>>With ElementTree going into Python 2.5, I suspect testbrowser will grow 
>>XPath support.
 >
> Great! (of course, if we could have it sooner....) :p

I'm hesitant to add another dependency to Zope 3, especially something 
as grotesque as libxml2. :)  ET seems like a good alternative.  We can 
add ET to Z3 (either the pure-Python or C version) and after Python 2.5 
is the oldest supported version, remove it.

> I looked at zope.testrecorder and thought, hey, that looks simple! Then 
> I saw the .js file... ;-)

Yeah, the implementation is necessarily somewhat hairy.

> Realistically, I don't think I'm likely to have time

Same here.

> Yeah, that was my thinking. Actually, I'd prefer if it just rendered it 
> as a '%s/foo' % base_url, where base_url was a variable. That way the 
> test case could do e.g. base_url = self.portal.absolute_url() and we 
> wouldn't have to hardcode anything.

For Zope 3 functional tests where the netloc is ignored that would 
unnecessarily clutter the resulting tests.  If it's going to be a fixed 
value, I prefer the current behavior.  Configurablity sounds good here.
-- 
Benji York
Senior Software Engineer
Zope Corporation


More information about the Zope3-dev mailing list