I am trying to install a policy product. Redid everything but keep getting an
error:
AttributeError: 'module' object has no attribute 'test_suite'
But that's not the frustration - when I compare my file test_setup.py to the
file in Optilux - the last procedure is not indented
in the Optilux but when I remove the indent - the whole test crashes big
and doesn't run.
When I retain the indent for def test_suite(): then I get a seemingly
controlled error - attribute error - which I also can't get to go away.
This is the error when I make test_setup.py look like Optilux's
test_setup.py -
Running tests at level 1
Installing CMFCore ... done (0.306s)
Installing CMFDefault ... done (0.235s)
Installing CMFCalendar ... done (0.041s)
Installing CMFTopic ... done (0.024s)
Installing DCWorkflow ... done (0.061s)
Installing CMFActionIcons ... done (0.024s)
Installing CMFQuickInstallerTool ... done (0.064s)
Installing CMFFormController ... done (0.359s)
Installing GroupUserFolder ... done (0.409s)
Installing ZCTextIndex ... done (0.060s)
Installing CMFPlone ... done (2.311s)
Installing Archetypes ... done (0.114s)
Installing ATContentTypes ... done (0.047s)
Installing ATReferenceBrowserWidget ... done (0.013s)
Installing CMFDynamicViewFTI ... done (0.013s)
Installing ExternalEditor ... done (0.017s)
Installing ExtendedPathIndex ... done (0.016s)
Installing ResourceRegistries ... done (0.015s)
Installing SecureMailHost ... done (0.014s)
Installing CMFPlacefulWorkflow ... done (0.066s)
Installing PasswordResetTool ... done (0.016s)
Installing PluggableAuthService ...
/home/webmaster/afewtips/parts/plone/GenericSetup/registry.py:744:
DeprecationWarning: Version for profile PluggableAuthService:simple taken
from version.txt. This is deprecated behaviour and will be removed in
GenericSetup 1.5: please specify the version in metadata.xml.
DeprecationWarning)
/home/webmaster/afewtips/parts/plone/GenericSetup/registry.py:744:
DeprecationWarning: Version for profile PluggableAuthService:empty taken
from version.txt. This is deprecated behaviour and will be removed in
GenericSetup 1.5: please specify the version in metadata.xml.
DeprecationWarning)
done (0.024s)
Installing PluginRegistry ... done (0.018s)
Installing PlonePAS ... done (0.024s)
Installing kupu ... done (0.266s)
Installing CMFEditions ... done (0.026s)
Installing CMFDiffTool ... done (0.024s)
Installing PloneLanguageTool ... done (0.030s)
Running Products.PloneTestCase.layer.PloneSite tests:
Set up Products.PloneTestCase.layer.ZCML
Traceback (most recent call last):
File "./bin/instance", line 58, in ?
plone.recipe.zope2instance.ctl.main(
File
"/home/webmaster/afewtips/eggs/plone.recipe.zope2instance-2.4-py2.4.egg/plone/recipe/zope2instance/ctl.py",
line 235, in main
c.onecmd(" ".join(options.args))
File "/usr/lib/python2.4/cmd.py", line 219, in onecmd
return func(arg)
File
"/home/webmaster/afewtips/eggs/plone.recipe.zope2instance-2.4-py2.4.egg/plone/recipe/zope2instance/ctl.py",
line 202, in do_test
zope.testing.testrunner.run(defaults, args)
File
"/home/webmaster/afewtips/parts/zope2/lib/python/zope/testing/testrunner.py",
line 271, in run
failed = not run_with_options(options)
File
"/home/webmaster/afewtips/parts/zope2/lib/python/zope/testing/testrunner.py",
line 433, in run_with_options
setup_layers, failures, errors)
File
"/home/webmaster/afewtips/parts/zope2/lib/python/zope/testing/testrunner.py",
line 604, in run_layer
setup_layer(layer, setup_layers)
File
"/home/webmaster/afewtips/parts/zope2/lib/python/zope/testing/testrunner.py",
line 688, in setup_layer
setup_layer(base, setup_layers)
File
"/home/webmaster/afewtips/parts/zope2/lib/python/zope/testing/testrunner.py",
line 692, in setup_layer
layer.setUp()
File "/home/webmaster/afewtips/parts/plone/PloneTestCase/layer.py", line
17, in setUp
five.safe_load_site()
File "/home/webmaster/afewtips/parts/plone/PloneTestCase/five.py", line
39, in safe_load_site
zcml.load_site()
File
"/home/webmaster/afewtips/parts/zope2/lib/python/Products/Five/zcml.py",
line 53, in load_site
_context = xmlconfig.file(file)
File
"/home/webmaster/afewtips/parts/zope2/lib/python/zope/configuration/xmlconfig.py",
line 579, in file
include(context, name, package)
File
"/home/webmaster/afewtips/parts/zope2/lib/python/zope/configuration/xmlconfig.py",
line 515, in include
processxmlfile(f, context)
File
"/home/webmaster/afewtips/parts/zope2/lib/python/zope/configuration/xmlconfig.py",
line 370, in processxmlfile
parser.parse(src)
File "/usr/lib/python2.4/xml/sax/expatreader.py", line 107, in parse
xmlreader.IncrementalParser.parse(self, source)
File "/usr/lib/python2.4/xml/sax/xmlreader.py", line 123, in parse
self.feed(buffer)
File "/usr/lib/python2.4/xml/sax/expatreader.py", line 207, in feed
self._parser.Parse(data, isFinal)
File "/usr/lib/python2.4/xml/sax/expatreader.py", line 348, in
end_element_ns
self._cont_handler.endElementNS(pair, None)
File
"/home/webmaster/afewtips/parts/zope2/lib/python/zope/configuration/xmlconfig.py",
line 349, in endElementNS
self.context.end()
File
"/home/webmaster/afewtips/parts/zope2/lib/python/zope/configuration/config.py",
line 544, in end
self.stack.pop().finish()
File
"/home/webmaster/afewtips/parts/zope2/lib/python/zope/configuration/config.py",
line 692, in finish
actions = self.handler(context, **args)
File
"/home/webmaster/afewtips/parts/zope2/lib/python/zope/configuration/xmlconfig.py",
line 515, in include
processxmlfile(f, context)
File
"/home/webmaster/afewtips/parts/zope2/lib/python/zope/configuration/xmlconfig.py",
line 370, in processxmlfile
parser.parse(src)
File "/usr/lib/python2.4/xml/sax/expatreader.py", line 107, in parse
xmlreader.IncrementalParser.parse(self, source)
File "/usr/lib/python2.4/xml/sax/xmlreader.py", line 123, in parse
self.feed(buffer)
File "/usr/lib/python2.4/xml/sax/expatreader.py", line 207, in feed
self._parser.Parse(data, isFinal)
File "/usr/lib/python2.4/xml/sax/expatreader.py", line 348, in
end_element_ns
self._cont_handler.endElementNS(pair, None)
File
"/home/webmaster/afewtips/parts/zope2/lib/python/zope/configuration/xmlconfig.py",
line 349, in endElementNS
self.context.end()
File
"/home/webmaster/afewtips/parts/zope2/lib/python/zope/configuration/config.py",
line 544, in end
self.stack.pop().finish()
File
"/home/webmaster/afewtips/parts/zope2/lib/python/zope/configuration/config.py",
line 692, in finish
actions = self.handler(context, **args)
File
"/home/webmaster/afewtips/parts/zope2/lib/python/zope/configuration/xmlconfig.py",
line 515, in include
processxmlfile(f, context)
File
"/home/webmaster/afewtips/parts/zope2/lib/python/zope/configuration/xmlconfig.py",
line 370, in processxmlfile
parser.parse(src)
File "/usr/lib/python2.4/xml/sax/expatreader.py", line 107, in parse
xmlreader.IncrementalParser.parse(self, source)
File "/usr/lib/python2.4/xml/sax/xmlreader.py", line 123, in parse
self.feed(buffer)
File "/usr/lib/python2.4/xml/sax/expatreader.py", line 207, in feed
self._parser.Parse(data, isFinal)
File "/usr/lib/python2.4/xml/sax/expatreader.py", line 348, in
end_element_ns
self._cont_handler.endElementNS(pair, None)
File
"/home/webmaster/afewtips/parts/zope2/lib/python/zope/configuration/xmlconfig.py",
line 349, in endElementNS
self.context.end()
File
"/home/webmaster/afewtips/parts/zope2/lib/python/zope/configuration/config.py",
line 544, in end
self.stack.pop().finish()
File
"/home/webmaster/afewtips/parts/zope2/lib/python/zope/configuration/config.py",
line 691, in finish
args = toargs(context, *self.argdata)
File
"/home/webmaster/afewtips/parts/zope2/lib/python/zope/configuration/config.py",
line 1383, in toargs
args[str(name)] = field.fromUnicode(s)
File
"/home/webmaster/afewtips/parts/zope2/lib/python/zope/configuration/fields.py",
line 141, in fromUnicode
raise schema.ValidationError(v)
zope.configuration.xmlconfig.ZopeXMLConfigurationError: File
"/home/webmaster/afewtips/parts/instance/etc/site.zcml", line 14.2-14.55
ZopeXMLConfigurationError: File
"/home/webmaster/afewtips/parts/instance/etc/package-includes/001-afewtips.policy-configure.zcml",
line 1.0-1.59
ZopeXMLConfigurationError: File
"/home/webmaster/afewtips/src/afewtips.policy/afewtips/policy/configure.zcml",
line 7.4-7.65
ConfigurationError: ('Invalid value for', 'initialize', 'ImportError:
Module afewtips.policy has no global initialize')
--
View this message in context:
http://n2.nabble.com/Getting-Frustrated---policy-product---this-shouldn%27t-be-this-difficult-tp1089193p1089193.html
Sent from the Installation, Setup, Upgrades mailing list archive at Nabble.com.
_______________________________________________
Setup mailing list
[email protected]
http://lists.plone.org/mailman/listinfo/setup