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

Philipp von Weitershausen wrote:
> Log message for revision 68244:
>   Fix a test that was testing wrong behaviour: primitive types
>   werent' called if they were the result of a path expression, while
>   all other callables were called. This tests now tests the correct
>   behaviour (which happens to be already implemented by the Zope 3
>   TALES engine)

> +        assert ec.evaluate('x | python:int') == 0

Wait a minute -- that isn't a path expression there!  The '|' is not
supposed to change the rules for evaluation of the subexpressions!  If
'int' or the like were somehow avaialbe at module scope, or via
'options' or another top-level name, then they should be called *when
they are the last item in a path expression*.

The test was actually correct beofore: because tne PathExpression, 'x',
raises, the PythonExpression, 'int', is evalutated.  The result of a
subexpression is not suppoeed to be called,

>          assert ec.evaluate('x | string:x') == 'x'
>          assert ec.evaluate('x | string:$one') == '1'
>          assert ec.evaluate('x | not:exists:x')
> 


- --
===================================================================
Tres Seaver          +1 202-558-7113          [EMAIL PROTECTED]
Palladion Software   "Excellence by Design"    http://palladion.com
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.1 (GNU/Linux)
Comment: Using GnuPG with Thunderbird - http://enigmail.mozdev.org

iD8DBQFEchs6+gerLs4ltQ4RAi9DAJ9X34bgQNfCq+RN4zj27OoU6/Et0QCfbEDn
IYaH04TINHsOQk36f2f19do=
=eW90
-----END PGP SIGNATURE-----

_______________________________________________
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 )

Reply via email to