From e4610566d881f707c01d266a7e336084029c83e4 Mon Sep 17 00:00:00 2001 From: Chris McDonough Date: Sun, 20 Sep 2009 22:13:11 +0000 Subject: - The way ``bfg_view`` declarations are scanned for has been modified. This should have no external effects. - An object implementing the ``IRenderer`` interface (and ``ITemplateRenderer`, which is a subclass of ``IRenderer``) must now accept an extra ``system`` argument in its ``__call__`` method implementation. Values computed by the system (as opposed to by the view) are passed by the system in the ``system`` parameter, which will always be a dictionary. Keys in the dictionary include: ``view`` (the view object that returned the value), ``renderer_name`` (the template name or simple name of the renderer), ``context`` (the context object passed to the view), and ``request`` (the request object passed to the view). Previously only ITemplateRenderers received system arguments as elements inside the main ``value`` dictionary. --- repoze/bfg/testing.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'repoze/bfg/testing.py') diff --git a/repoze/bfg/testing.py b/repoze/bfg/testing.py index d4aafa083..1c7693306 100644 --- a/repoze/bfg/testing.py +++ b/repoze/bfg/testing.py @@ -270,7 +270,7 @@ class DummyTemplateRenderer: return self(kw) return callit - def __call__(self, kw): + def __call__(self, kw, system=None): self._received.update(kw) return self.string_response -- cgit v1.2.3