[Grok-dev] compattest recipe: automatically test dependencies
Reinout van Rees
reinout at vanrees.org
Fri Dec 11 16:45:10 EST 2009
Hi all,
I made an addition to z3c.recipe.compattest on the
"reinout-requirements" branch.
Problem 1: normally you have to specify all the packages you want to
test by hand in the ``include`` option. If you have a new dependency,
you can easily forget to list it.
Problem 2: we use plone.recipe.alltests, which tests everything testable
that's available. Problem is that you have to manually exclude a whole
list of packages that have bad or non-runnable tests. With grok 1.0 we
had to exclude some 15 zope.app.* packages, for instance, as their tests
didn't run.
Solution: use z3c.recipe.compattest, but fill in the list of packages
automatically. You specify one (or more) packages in
``include-dependencies`` instead of ``include`` and
z3c.recipe.compattest picks them up AND adds their dependencies you
listed in setup.py.
Your compattest part can be as short as::
[compattest]
recipe = z3c.recipe.compattest
include-dependencies = my.package
Assuming you've got your setup.py dependencies up to date (use
z3c.dependencychecker!), your bin/compattest will test those packages
that are most useful to test. And if you add a dependency, your
compattest will include it.
The branch is at:
http://svn.zope.org/repos/main/z3c.recipe.compattest/branches/reinout-requirements/
Is it OK for me to merge it? (Or for someone else to do it; including a
release pretty please :-) )
Reinout
--
Reinout van Rees - reinout at vanrees.org - http://reinout.vanrees.org
Software developer at http://www.thehealthagency.com
"Military engineers build missiles. Civil engineers build targets"
More information about the Grok-dev
mailing list