[Zope-CMF] Re: test failures

Tres Seaver tseaver at zope.com
Fri Apr 22 14:35:01 EDT 2005


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Tres Seaver wrote:

> Florent Guillaume wrote:
> 
>>>I have strange failures with Zope 2.7 HEAD and CMF 1.4 HEAD:
>>>
>>>Running
>>>  bin/zopectl test -vv --dir Products/CMFCore test_PortalFolder
>>>works.
>>>
>>>But running
>>>  bin/zopectl test -vv --dir Products/CMFCore
>>>gives:
>>>
>>>======================================================================
>>>ERROR: test_invokeFactory
>>>(Products.CMFCore.tests.test_PortalFolder.PortalFolderFactoryTests)
>>>----------------------------------------------------------------------
>>>Traceback (most recent call last):
>>>  File
>>>"/home/zopes/zope27head/Products/CMFCore/tests/test_PortalFolder.py",
>>>line 78, in test_invokeFactory
>>>    f.invokeFactory( type_name='Dummy Content', id='foo' )
>>>  File "/home/zopes/zope27head/Products/CMFCore/PortalFolder.py", line
>>>367, in invokeFactory
>>>    pt.constructContent(type_name, self, id, RESPONSE, *args, **kw)
>>>  File "/home/zopes/zope27head/Products/CMFCore/TypesTool.py", line 709,
>>>in constructContent
>>>    ob = info.constructInstance(container, id, *args, **kw)
>>>  File "/home/zopes/zope27head/Products/CMFCore/TypesTool.py", line 388,
>>>in constructInstance
>>>    m = self._getFactoryMethod(container)
>>>  File "/home/zopes/zope27head/Products/CMFCore/TypesTool.py", line 334,
>>>in _getFactoryMethod
>>>    raise ValueError, ('Product factory for %s was undefined' %
>>>ValueError: Product factory for  was undefined
>>>
>>>======================================================================
>>>FAIL: test_contentPaste
>>>(Products.CMFCore.tests.test_PortalFolder.PortalFolderTests)
>>>----------------------------------------------------------------------
>>>Traceback (most recent call last):
>>>  File
>>>"/home/zopes/zope27head/Products/CMFCore/tests/test_PortalFolder.py",
>>>line 370, in test_contentPaste
>>>    assert 'dummy' in sub1.contentIds()
>>>AssertionError
>>>
>>>----------------------------------------------------------------------
>>>Ran 432 tests in 71.072s
>>>
>>>FAILED (failures=1, errors=1)
>>>
>>>
>>>Any ideas ?
> 
> 
> I see the same issue when running all CMF tests on the 1.4 branch.  I
> would bet that some test case module, whose tests run before
> 'test_PortalFolder', is failing to clean something up.

Hmm, if I remove the 'test_all' fossil on the 1.4 branch, and run the
tests using 'bin/zopectl test', all is well -- the tests are actually
failing the second time through, when somebody has stomped on the
'DummyFTI' instance imported from 'Products.CMFCore.tests.base.dummy'.

Would anyone be torqued if we removed all the 'test_all' shims from the
CMF 1.4 branch?  All they are doing now is making it take longer to run
tests, and potentially creating testing bugs.


Tres.
- --
===============================================================
Tres Seaver                                tseaver at zope.com
Zope Corporation      "Zope Dealers"       http://www.zope.com
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.2.5 (GNU/Linux)
Comment: Using GnuPG with Thunderbird - http://enigmail.mozdev.org

iD8DBQFCaUPVGqWXf00rNCgRAsEbAJ9VzMnhAnHEYbAPy+JiapDpG91IfgCfewo9
roM4Z1g6kcSGVHHH8Y+gz/A=
=JKWw
-----END PGP SIGNATURE-----



More information about the Zope-CMF mailing list