]> git.ipfire.org Git - thirdparty/sqlalchemy/sqlalchemy.git/commitdiff
- set sqla_nose as the setup.py test runner - works !
authorMike Bayer <mike_mp@zzzcomputing.com>
Tue, 16 Nov 2010 18:33:48 +0000 (13:33 -0500)
committerMike Bayer <mike_mp@zzzcomputing.com>
Tue, 16 Nov 2010 18:33:48 +0000 (13:33 -0500)
README.unittests
setup.py
sqla_nose.py

index 6c4353b35a30b7d54d5582c64f13e4dbb407b3e2..b9e37db7cbbb392a99711fd8a7c3d8cd8cb1b46f 100644 (file)
@@ -5,32 +5,33 @@ SQLALCHEMY UNIT TESTS
 SQLAlchemy unit tests by default run using Python's built-in sqlite3 
 module.  If running on Python 2.4, pysqlite must be installed.
 
-Unit tests are run using nose.  Note that in most cases,
-nose needs to be installed manually.  Documentation and
-downloads for nose are available at:
+Unit tests are run using nose.  Nose is available at:
 
-http://somethingaboutorange.com/mrl/projects/nose/0.11.1/index.html
-
-Or using setuptools:
-
-    $ easy_install nose
+    http://pypi.python.org/pypi/nose/
 
 SQLAlchemy implements a nose plugin that must be present when tests are run.
 This plugin is invoked when the test runner script provided with
 SQLAlchemy is used.
 
 **NOTE:** - the nose plugin is no longer installed by setuptools as of 
-version 0.7 !  Please use sqla_nose.py to run tests.
+version 0.7 !  Use "python setup.py test" or "./sqla_nose.py".
+
+RUNNING TESTS VIA SETUP.PY
+--------------------------
+A plain vanilla run of all tests using sqlite can be run via setup.py:
+
+    $ python setup.py test
 
-RUNNING ALL TESTS
------------------
+The -v flag also works here:
+
+    $ python setup.py test -v
+
+RUNNING ALL TESTS 
+------------------
 To run all tests:
 
     $ ./sqla_nose.py
 
-(NOTE: if running with Python 2.7 and nose 0.11.3, add "-w test/" to the command.
-Again this is a Nose issue, see Nose issue 342.)
-
 If you're running the tests on Microsoft Windows, then there is an additional
 argument that must be passed to ./sqla_nose.py:
 
index 0e9b18c665db1f281fcd27d29dc5cce925cac1d1..e3bdfeff8ebe7abc06e9ac23c71b85704ee37788 100644 (file)
--- a/setup.py
+++ b/setup.py
@@ -82,12 +82,8 @@ setup(name = "SQLAlchemy",
       package_dir = {'':'lib'},
       license = "MIT License",
 
-      # TODO: this is nice, but Python 3 support ?
-      # any way to make it not install for build/install ?
-      #setup_requires=["setuptools_hg"],
-
       tests_require = ['nose >= 0.11'],
-      test_suite = "nose.collector",
+      test_suite = "sqla_nose",
       
       long_description = """\
 SQLAlchemy is:
index e6f60e47671e91238d3065efff97b49be5100e58..09481410c2d54aae7f933aead6baa27da0e73970 100755 (executable)
@@ -16,5 +16,4 @@ from test.bootstrap.noseplugin import NoseSQLAlchemy
 
 import nose
 
-if __name__ == '__main__':
-    nose.main(addplugins=[NoseSQLAlchemy()])
+nose.main(addplugins=[NoseSQLAlchemy()])