Welcome, guest | Sign In | My Account | Store | Cart

Notice! PyPM is being replaced with the ActiveState Platform, which enhances PyPM’s build and deploy capabilities. Create your free Platform account to download ActivePython or customize Python with the packages you require and get automatic updates.

Download
ActivePython
INSTALL>
pypm install chaoflow.testing.crawler

How to install chaoflow.testing.crawler

  1. Download and install ActivePython
  2. Open Command Prompt
  3. Type pypm install chaoflow.testing.crawler
 Python 2.7Python 3.2Python 3.3
Windows (32-bit)
0.5 Available View build log
Windows (64-bit)
0.5 Available View build log
Mac OS X (10.5+)
0.5 Available View build log
Linux (32-bit)
0.5 Available View build log
Linux (64-bit)
0.5 Available View build log
 
License
LGPL
Lastest release
version 0.5 on Jan 5th, 2011

Introduction

The purpose of chaoflow.testing.crawler is to find tests in your package and run them along with tests in files you explicitly define.

Tests are found in the following files:

  • all .py files that are part of (subpackages of) your package, i.e. files that

System Message: WARNING/2 (<string>, line 10)

Bullet list ends without a blank line; unexpected unindent.

you can import with import - all .txt files that have a corresponding .py file - all files you excplicitly specify

All tests found can be run individually, e.g. with zc.recipe.testrunner.

Using the test crawler

In order to use the test crawler for your package, you only need to copy one file and declare the dependency on chaoflow.testing.crawler in your setup.py.

Drop this file into your package root and adapt the files list to explicitly specify test files that are not found otherwise, tests.py:

# chaoflow.testing.crawler.tests.py
#
# You can simply copy this file to your package and adjust it to your needs

from chaoflow.testing.crawler import create_test_suite

# File to test, relative to the package root # all .py files are found # all .txt files with corresponding .py file are found files = [ 'README.txt' ]

# We assume that this modules is in the root of your package pkgname = __name__[:-6]

test_suite = create_test_suite(pkgname, files)

Declare the dependency in setup.py:

System Message: WARNING/2 (<string>, line 50)

Literal block expected; none found.

setup(... extras_require={ 'test': [ 'interlude', 'chaoflow.testing.ipython', 'chaoflow.testing.crawler', ], }, )

If interlude is available, interlude.interact will be available as interact in your test environment.

If chaoflow.testing.ipython is available, ipshell will be available as ipshell in your test environment.

example buildout.cfg using chaoflow.testing.crawler and zc.recipe.testrunner:

[buildout]

System Message: ERROR/3 (<string>, line 69)

Inconsistent literal block quoting.

develop = . parts = test py

[test] recipe = zc.recipe.testrunner eggs = chaoflow.testing.crawler [test]

[py] recipe = zc.recipe.egg interpreter = py eggs = ${test:eggs}

After buildout, you can run your tests using ./bin/test. Run ./bin/test --list-tests to get a list of all registered tests and see ./bin/test --help for further information.

License

chaoflow.testing.crawler is licensed under LGPLv3. Please let me know if this presents a problem for you.

Changelog

Subscribe to package updates

Last updated Jan 5th, 2011

Download Stats

Last month:1

What does the lock icon mean?

Builds marked with a lock icon are only available via PyPM to users with a current ActivePython Business Edition subscription.

Need custom builds or support?

ActivePython Enterprise Edition guarantees priority access to technical support, indemnification, expert consulting and quality-assured language builds.

Plan on re-distributing ActivePython?

Get re-distribution rights and eliminate legal risks with ActivePython OEM Edition.