[Zope-dev] Zope Tests: 5 OK

2007-06-12 Thread Zope Tests Summarizer
Summary of messages to the zope-tests list.
Period Mon Jun 11 12:00:00 2007 UTC to Tue Jun 12 12:00:00 2007 UTC.
There were 5 messages: 5 from Zope Unit Tests.


Tests passed OK
---

Subject: OK : Zope-2.7 Python-2.3.6 : Linux
From: Zope Unit Tests
Date: Mon Jun 11 20:51:44 EDT 2007
URL: http://mail.zope.org/pipermail/zope-tests/2007-June/007869.html

Subject: OK : Zope-2.8 Python-2.3.6 : Linux
From: Zope Unit Tests
Date: Mon Jun 11 20:53:17 EDT 2007
URL: http://mail.zope.org/pipermail/zope-tests/2007-June/007870.html

Subject: OK : Zope-2.9 Python-2.4.4 : Linux
From: Zope Unit Tests
Date: Mon Jun 11 20:54:48 EDT 2007
URL: http://mail.zope.org/pipermail/zope-tests/2007-June/007871.html

Subject: OK : Zope-2.10 Python-2.4.4 : Linux
From: Zope Unit Tests
Date: Mon Jun 11 20:56:25 EDT 2007
URL: http://mail.zope.org/pipermail/zope-tests/2007-June/007872.html

Subject: OK : Zope-trunk Python-2.4.4 : Linux
From: Zope Unit Tests
Date: Mon Jun 11 20:57:59 EDT 2007
URL: http://mail.zope.org/pipermail/zope-tests/2007-June/007873.html

___
Zope-Dev maillist  -  Zope-Dev@zope.org
http://mail.zope.org/mailman/listinfo/zope-dev
**  No cross posts or HTML encoding!  **
(Related lists - 
 http://mail.zope.org/mailman/listinfo/zope-announce
 http://mail.zope.org/mailman/listinfo/zope )


[Zope-dev] Re: Testing zope 3 utilities from zope 2

2007-06-12 Thread David Convent
I've been looking for a solution during hours before posting the 
question, and of course I found the solution right after posting it.


I needed to use the setHooks() and setSite() from zope.app.component.hooks

Sorry for the noise on the list,
David

David Convent wrote:

hi,

I'm writing a unit test for GS exportimport of the Plone 3.0 
plone.app.viewletmanager product.

the exportimport handler configures a storage which is a Zope 3 utility.

As I want to include support for same node attributes than the skins 
tool exportimport handler, I took inspiration from the tests in 
CMFCore/exportimport/tests.


My problem is that the utility keeps its settings in all test methods of 
a test case.

Therefore, I can not properly test the exportimport steps.

I tried to call unregisterUtility() in the tearDown() method of the test 
class but that doesn't change anything.


Any suggesion on how to solve this particular problem?

Current state of the code is in 
https://svn.plone.org/svn/plone/plone.app.viewletmanager/branches/6649-default-order-support/tests/test_exportimport.py 



the test_z_means_last() test method output make it obvious, the utility 
keeps its settings.


Thank you in advance,
David

___
Zope-Dev maillist  -  Zope-Dev@zope.org
http://mail.zope.org/mailman/listinfo/zope-dev
**  No cross posts or HTML encoding!  **
(Related lists - http://mail.zope.org/mailman/listinfo/zope-announce
http://mail.zope.org/mailman/listinfo/zope )



___
Zope-Dev maillist  -  Zope-Dev@zope.org
http://mail.zope.org/mailman/listinfo/zope-dev
**  No cross posts or HTML encoding!  **
(Related lists - 
http://mail.zope.org/mailman/listinfo/zope-announce

http://mail.zope.org/mailman/listinfo/zope )


[Zope-dev] Testing zope 3 utilities from zope 2

2007-06-12 Thread David Convent

hi,

I'm writing a unit test for GS exportimport of the Plone 3.0 
plone.app.viewletmanager product.

the exportimport handler configures a storage which is a Zope 3 utility.

As I want to include support for same node attributes than the skins 
tool exportimport handler, I took inspiration from the tests in 
CMFCore/exportimport/tests.


My problem is that the utility keeps its settings in all test methods of 
a test case.

Therefore, I can not properly test the exportimport steps.

I tried to call unregisterUtility() in the tearDown() method of the test 
class but that doesn't change anything.


Any suggesion on how to solve this particular problem?

Current state of the code is in 
https://svn.plone.org/svn/plone/plone.app.viewletmanager/branches/6649-default-order-support/tests/test_exportimport.py


the test_z_means_last() test method output make it obvious, the utility 
keeps its settings.


Thank you in advance,
David

___
Zope-Dev maillist  -  Zope-Dev@zope.org
http://mail.zope.org/mailman/listinfo/zope-dev
**  No cross posts or HTML encoding!  **
(Related lists - 
http://mail.zope.org/mailman/listinfo/zope-announce

http://mail.zope.org/mailman/listinfo/zope )