Hi,
I suggest defining __add__ for zope.testing.renormalizing.RENormalizing which would return a new Checker with the transformers combined.
This allow better reuse of those checkers without having to define the patterns separately. Like
checker = checker_a + checker_b.
Comments?
On Jun 18, 2009, at 4:00 AM, Christian Zagrodnick wrote:
Hi,
I suggest defining __add__ for zope.testing.renormalizing.RENormalizing which would return a new Checker with the transformers combined.
This allow better reuse of those checkers without having to define the patterns separately. Like
checker = checker_a + checker_b.
Comments?
+1
Jim
-- Jim Fulton Zope Corporation
Hello Christian,
Good idea, see svn://svn.zope.org/repos/main/zope.testing/trunk/src/zope/testing/testrunner/tests.py
A problem might be at the above case the order of replacements.
Thursday, June 18, 2009, 10:00:01 AM, you wrote:
CZ> Hi,
CZ> I suggest defining __add__ for CZ> zope.testing.renormalizing.RENormalizing CZ> which would return a new Checker with the transformers combined.
CZ> This allow better reuse of those checkers without having to define the CZ> patterns separately. Like
CZ> checker = checker_a + checker_b.
CZ> Comments?
On 2009-06-18 10:00:01 +0200, Christian Zagrodnick cz@gocept.com said:
Hi,
I suggest defining __add__ for zope.testing.renormalizing.RENormalizing
which would return a new Checker with the transformers combined.
This allow better reuse of those checkers without having to define the
patterns separately. Like
checker = checker_a + checker_b.
Finally got that in: r106221.