buildout recipe to create scripts to run testrepository.
Project description
testr recipe
============
This allows you to easily add a testrepository script to your buildout
project. This really only means that the user doesn't have to have
testr on their path, and they can just use ./bin/test or simlar.
This works very similarly to zc.recipe.testrunner, and in fact borrows
most of its code from there.
A sample buildout configuration would be::
[buildout]
develop = .
parts = test
[test]
recipe = testr_recipe
script = test
which will have ./bin/test run using the .testr.conf in your root
dir.
These are the options you can use:
* script: define the name of the script to create, if not passed
then the name of the section will be used.
* working-directory: if somewhere other than the root of the project
should be used.
* environment: the name of a section containing pairs of values to
put in the environment for the test run, e.g.
::
[test]
recipe = testr_recipe
enironment = testenv
[testenv]
foo = bar
zap = zang
* initialization: a string containing python code to put in the test
script before testr is run.
* executable: the python executable to put in the #! of the script.
* defaults: a list of options to prepend sys.argv for testr.
These are specified as Python source for an expression yielding a list,
typically a list literal. One thing you can do with this is::
[buildout]
parts = test testr
[testr]
recipe = testr_recipe
[test]
recipe = testr_recipe
defaults = ["run"]
which will make ./bin/test run the tests, and allow you to use
./bin/testr to access all the features of testr.
Future enhancments:
* Maybe automatically doing "testr init" when setting up the project, so that
./bin/test works straight away.
* Automatically generate a .testr.conf using standard mechanisms.
============
This allows you to easily add a testrepository script to your buildout
project. This really only means that the user doesn't have to have
testr on their path, and they can just use ./bin/test or simlar.
This works very similarly to zc.recipe.testrunner, and in fact borrows
most of its code from there.
A sample buildout configuration would be::
[buildout]
develop = .
parts = test
[test]
recipe = testr_recipe
script = test
which will have ./bin/test run using the .testr.conf in your root
dir.
These are the options you can use:
* script: define the name of the script to create, if not passed
then the name of the section will be used.
* working-directory: if somewhere other than the root of the project
should be used.
* environment: the name of a section containing pairs of values to
put in the environment for the test run, e.g.
::
[test]
recipe = testr_recipe
enironment = testenv
[testenv]
foo = bar
zap = zang
* initialization: a string containing python code to put in the test
script before testr is run.
* executable: the python executable to put in the #! of the script.
* defaults: a list of options to prepend sys.argv for testr.
These are specified as Python source for an expression yielding a list,
typically a list literal. One thing you can do with this is::
[buildout]
parts = test testr
[testr]
recipe = testr_recipe
[test]
recipe = testr_recipe
defaults = ["run"]
which will make ./bin/test run the tests, and allow you to use
./bin/testr to access all the features of testr.
Future enhancments:
* Maybe automatically doing "testr init" when setting up the project, so that
./bin/test works straight away.
* Automatically generate a .testr.conf using standard mechanisms.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
testr_recipe-0.2.tar.gz
(3.7 kB
view details)
Built Distribution
testr_recipe-0.2-py2.6.egg
(5.4 kB
view details)
File details
Details for the file testr_recipe-0.2.tar.gz
.
File metadata
- Download URL: testr_recipe-0.2.tar.gz
- Upload date:
- Size: 3.7 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | f3bf6d8bc102ff0fc092b90db478f9be0a510e1140484b47ec98c54992edab57 |
|
MD5 | d49602e27bce09e26189b50a49207032 |
|
BLAKE2b-256 | bef32b6f58c5096e255cd55844be26f37158145e3e97d91c3e530a7f1fc9a087 |
File details
Details for the file testr_recipe-0.2-py2.6.egg
.
File metadata
- Download URL: testr_recipe-0.2-py2.6.egg
- Upload date:
- Size: 5.4 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 6786844832f9994828f7de5a070f39173ab463f43aba23976c49be4c5a45c9d3 |
|
MD5 | 2327a1826df4dacb16178991b90b0cea |
|
BLAKE2b-256 | b56d9dd4b2826df8e285451f87a8d6b0532ac33a95c5e55b8bd323d497fd0ddf |