astropy/astropy — pull request #30 by iguananaut (2011-10-21 21:10:05+00:00)
Title: Add a 'test' command to setup.py

Adds a 'test' command to the setup.py (distribute comes with a test command but it doesn't work with py.test, so this replaces it outright). This also supports all the existing options to `astropy.test()` such as `module` and `verbose`.

With this it's possible to run all the tests with just `setup.py test` even if astropy hasn't been installed or built yet. If necessary it will first build extension modules and make them importable.