[SciPy-dev] [OT] Skipping a function wronlgy identified by nose

Matthew Brett matthew.brett at gmail.com
Thu Feb 19 16:41:25 EST 2009


Hi,

> Here is the problem: in our library, we have a perfectly valid function
> that is called 'onesample_test'. Due to the name, nose identifies it as a
> function (also because it is defined in a file called
> 'statistical_test.py').

Probably you want:

from numpy.testing import dec

@dec.setastest(False)
def function_that_tests():
   pass

If you don't want to import the decorator, just

def function_that_tests():
    pass
function_that_tests.__test__ = False

?

Matthew



More information about the SciPy-Dev mailing list