[Zope-CMF] Testing skin scripts and templates using
ZopeTestCase.Functional
Jens Vagelpohl
jens at dataflake.org
Wed Oct 5 17:35:01 EDT 2005
> def test_DocView(self):
> url = self.doc1.absolute_url_path()
> import pdb; pdb.set_trace()
> response = self.publish(url, self.basic_auth)
>
>
> Some stepping around with pdb reveals this:
> ....
> (Pdb) n
>
>> /zope/ZopeSoftwareHome/lib/python/ZPublisher/Publish.py(101)publish()
>>
> -> request, bind=1)
> (Pdb) n
> NotFound: 'document_view'
The machinery doesn't know which skin is selected I presume. You can
"force" it by calling "changeSkin" on the skinnable object manager
(the portal is one) to select a skin path as set up in the skins tool:
self.portal.changeSkin('Nouvelle')
jens
More information about the Zope-CMF
mailing list