File tree Expand file tree Collapse file tree 1 file changed +8
-8
lines changed Expand file tree Collapse file tree 1 file changed +8
-8
lines changed Original file line number Diff line number Diff line change 25
25
26
26
27
27
class NipypeTester (object ):
28
- def __call__ (self , doctests = True ):
28
+ def __call__ (self , doctests = True , parallel = True ):
29
29
try :
30
30
import pytest
31
31
except :
32
32
raise RuntimeError (
33
33
'py.test not installed, run: pip install pytest' )
34
- params = { 'args' : []}
35
- if doctests :
36
- params [ ' args' ]. append ( '-- doctest-modules' )
37
- nipype_path = os . path . dirname ( __file__ )
38
- params [ ' args' ]. extend (
39
- [ '-x' , '--ignore={}/external' . format ( nipype_path ), nipype_path ] )
40
- pytest .main (** params )
34
+ args = []
35
+ if not doctests :
36
+ args . extend ([ '-p' , 'no: doctest' ] )
37
+ if not parallel :
38
+ args . append ( '-n0' )
39
+ args . append ( os . path . dirname ( __file__ ) )
40
+ pytest .main (args = args )
41
41
42
42
43
43
test = NipypeTester ()
You can’t perform that action at this time.
0 commit comments