My favorites | Sign in
Project Logo
                
Search
for
Updated Apr 12, 2008 by paul.joseph.davis
Labels: Featured
TextMateFormatter  
Using the TextMateFormatter

TextMate Setup

Using the bundle editor, change the command for "Run Project Unit Tests" in the python bundle to be something like:

cd $TM_PROJECT_DIRECTORY ; nosetests --xml --xml-formatter=nosexml.TextMateFormatter

Then trigger the command to see the test results stream into an HTML window.

Adding Coverage

Change the command to:

cd $TM_PROJECT_DIRECTORY ; nosetests --xml --xml-formatter=nosexml.TextMateFormatter --with-coverage ${NOSE_EXTRA}

I use a project environment variable NOSE_EXTRA with the value of a the package I want to cover so I don't have to see a coverage report for all imported modules.


Comment by gfxmonk, Dec 08, 2008

is there an action to run tests for the current file? (or the tests in the current file if it ends in 'test.py')?

That would be great, but I can't figure it out...


Sign in to add a comment
Hosted by Google Code