[Checkins] SVN: grok/branches/ksmith_mcweekly-viewlet/ includes
ftests/url patch, fix bug in ViewletManagerGrokker
Kevin Smith
kevin at mcweekly.com
Fri Apr 27 12:19:37 EDT 2007
Log message for revision 74863:
includes ftests/url patch, fix bug in ViewletManagerGrokker
Changed:
U grok/branches/ksmith_mcweekly-viewlet/buildout.cfg
U grok/branches/ksmith_mcweekly-viewlet/src/grok/ftests/url/url_function.py
U grok/branches/ksmith_mcweekly-viewlet/src/grok/meta.py
-=-
Modified: grok/branches/ksmith_mcweekly-viewlet/buildout.cfg
===================================================================
--- grok/branches/ksmith_mcweekly-viewlet/buildout.cfg 2007-04-27 16:01:12 UTC (rev 74862)
+++ grok/branches/ksmith_mcweekly-viewlet/buildout.cfg 2007-04-27 16:19:36 UTC (rev 74863)
@@ -1,8 +1,9 @@
[buildout]
develop = . grokwiki ldapaddressbook
-parts = zope3 data instance testdata testinstance test
+parts = data instance testdata testinstance test
[zope3]
+location =/root/Zope-3.3.1
recipe = zc.recipe.zope3checkout
url = svn://svn.zope.org/repos/main/Zope3/branches/3.3
@@ -54,7 +55,7 @@
[test]
recipe = zc.recipe.testrunner
eggs = grok
-extra-paths = parts/zope3/src
+extra-paths = /root/Zope-3.3.1/lib/python
working-directory = parts/testinstance
defaults = ['--tests-pattern', '^f?tests$',
'-v'
Modified: grok/branches/ksmith_mcweekly-viewlet/src/grok/ftests/url/url_function.py
===================================================================
--- grok/branches/ksmith_mcweekly-viewlet/src/grok/ftests/url/url_function.py 2007-04-27 16:01:12 UTC (rev 74862)
+++ grok/branches/ksmith_mcweekly-viewlet/src/grok/ftests/url/url_function.py 2007-04-27 16:19:36 UTC (rev 74863)
@@ -6,8 +6,8 @@
>>> from grok import url
>>> import grok
>>> grok.grok('grok.ftests.url.url_function')
-
- >>> from grok.ftests.url.url import Herd, Mammoth
+
+ >>> from grok.ftests.url.url_function import Herd, Mammoth
>>> herd = Herd()
>>> getRootFolder()['herd'] = herd
>>> manfred = Mammoth()
@@ -24,7 +24,7 @@
>>> browser.open("http://localhost/herd/manfred/another")
>>> print browser.contents
http://localhost/herd/manfred/another
-
+
We get the views manually so we can do a greater variety of url() calls:
>>> from zope import component
@@ -65,6 +65,7 @@
True
"""
import grok
+from grok import url
class Herd(grok.Container, grok.Model):
pass
@@ -77,7 +78,7 @@
class Index(grok.View):
def render(self):
return url(self.request, self)
-
+
class Another(grok.View):
def render(self):
return url(self.request, self)
Modified: grok/branches/ksmith_mcweekly-viewlet/src/grok/meta.py
===================================================================
--- grok/branches/ksmith_mcweekly-viewlet/src/grok/meta.py 2007-04-27 16:01:12 UTC (rev 74862)
+++ grok/branches/ksmith_mcweekly-viewlet/src/grok/meta.py 2007-04-27 16:19:36 UTC (rev 74863)
@@ -617,7 +617,7 @@
view_layer,
view_context),
provides=IViewletManager,
- name=factory.__name__.lower())
+ name=name)
class ViewletGrokker(grok.ClassGrokker):
More information about the Checkins
mailing list