原文:https://docs.scipy.org/doc/numpy/reference/generated/numpy.testing.decorators.setastest.html
校对:(虚位以待)
numpy.testing.decorators.setastest(tf=True)[source]信号到鼻子,这个函数是或不是一个测试。
| 参数: | tf:bool
|
|---|
笔记
这个装饰器不能使用鼻子命名空间,因为它可以从非测试模块调用。另请参见nose.tools中的istest和nottest。
例子
setastest可以按以下方式使用:
from numpy.testing.decorators import setastest
@setastest(False)
def func_with_test_in_name(arg1, arg2):
pass