[Zconfig] SVN: ZConfig/trunk/ make this a buildout, and use only the standard testrunner

Fred L. Drake, Jr. fdrake at gmail.com
Thu Jun 21 11:33:45 EDT 2007


Log message for revision 76902:
  make this a buildout, and use only the standard testrunner

Changed:
  D   ZConfig/trunk/ZConfig/tests/runtests.py
  A   ZConfig/trunk/buildout.cfg

-=-
Deleted: ZConfig/trunk/ZConfig/tests/runtests.py
===================================================================
--- ZConfig/trunk/ZConfig/tests/runtests.py	2007-06-21 14:18:54 UTC (rev 76901)
+++ ZConfig/trunk/ZConfig/tests/runtests.py	2007-06-21 15:33:45 UTC (rev 76902)
@@ -1,64 +0,0 @@
-#! /usr/bin/env python
-##############################################################################
-#
-# Copyright (c) 2002, 2003 Zope Corporation and Contributors.
-# All Rights Reserved.
-#
-# This software is subject to the provisions of the Zope Public License,
-# Version 2.1 (ZPL).  A copy of the ZPL should accompany this distribution.
-# THIS SOFTWARE IS PROVIDED "AS IS" AND ANY AND ALL EXPRESS OR IMPLIED
-# WARRANTIES ARE DISCLAIMED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
-# WARRANTIES OF TITLE, MERCHANTABILITY, AGAINST INFRINGEMENT, AND FITNESS
-# FOR A PARTICULAR PURPOSE.
-#
-##############################################################################
-"""Script to run all the regression tests for the ZConfig package."""
-
-import os
-import sys
-import unittest
-
-if __name__ == "__main__":
-    __file__ = sys.argv[0]
-
-TESTDIR = os.path.dirname(os.path.abspath(__file__))
-
-PKGDIR = os.path.dirname(TESTDIR) # the ZConfig package directory
-TOPDIR = os.path.dirname(PKGDIR)
-
-COMPONENTS = os.path.join(PKGDIR, "components")
-
-TESTDIRS = {
-    "ZConfig.tests": TESTDIR,
-    "ZConfig.components.basic.tests": os.path.join(COMPONENTS,
-                                                   "basic", "tests"),
-    "ZConfig.components.logger.tests": os.path.join(COMPONENTS,
-                                                    "logger", "tests"),
-    }
-
-
-def load_tests(pkgname, name):
-    name = "%s.%s" % (pkgname, name)
-    __import__(name)
-    mod = sys.modules[name]
-    return mod.test_suite()
-
-def test_suite():
-    L = []
-    for pkgname, path in TESTDIRS.items():
-        for fn in os.listdir(path):
-            name, ext = os.path.splitext(fn)
-            if name[:4] == "test" and ext == ".py":
-                L.append(load_tests(pkgname, name))
-    if len(L) == 1:
-        return L[0]
-    else:
-        suite = unittest.TestSuite()
-        for t in L:
-            suite.addTest(t)
-        return suite
-
-if __name__ == "__main__":
-    if TOPDIR not in sys.path:
-        sys.path.insert(0, TOPDIR)
-    unittest.main(defaultTest="test_suite")

Added: ZConfig/trunk/buildout.cfg
===================================================================
--- ZConfig/trunk/buildout.cfg	                        (rev 0)
+++ ZConfig/trunk/buildout.cfg	2007-06-21 15:33:45 UTC (rev 76902)
@@ -0,0 +1,9 @@
+[buildout]
+develop = .
+find-links = http://download.zope.org/distribution/
+parts = test
+
+[test]
+recipe = zc.recipe.testrunner
+eggs = ZConfig
+defaults = '--exit-with-status -1'.split()


Property changes on: ZConfig/trunk/buildout.cfg
___________________________________________________________________
Name: svn:mime-type
   + text/plain
Name: svn:eol-style
   + native



More information about the ZConfig mailing list