@@ -66,6 +66,8 @@ def __init__(self):
6666
6767
6868def test_BaseInterface ():
69+ config .set ('monitoring' , 'enable' , '0' )
70+
6971 assert nib .BaseInterface .help () is None
7072 assert nib .BaseInterface ._get_filecopy_info () == []
7173
@@ -82,6 +84,7 @@ class OutputSpec(nib.TraitedSpec):
8284
8385 class DerivedInterface (nib .BaseInterface ):
8486 input_spec = InputSpec
87+ resource_monitor = False
8588
8689 assert DerivedInterface .help () is None
8790 assert 'moo' in '' .join (DerivedInterface ._inputs_help ())
@@ -252,6 +255,8 @@ class DerivedInterface1(nib.BaseInterface):
252255 input_spec = InputSpec
253256 output_spec = OutputSpec
254257 _version = '0.10'
258+ resource_monitor = False
259+
255260 obj = DerivedInterface1 ()
256261 assert obj ._check_version_requirements (obj ._outputs ()) == []
257262
@@ -265,6 +270,8 @@ class DerivedInterface1(nib.BaseInterface):
265270 input_spec = InputSpec
266271 output_spec = OutputSpec
267272 _version = '0.10'
273+ resource_monitor = False
274+
268275 obj = DerivedInterface1 ()
269276 assert obj ._check_version_requirements (obj ._outputs ()) == ['foo' ]
270277
@@ -278,6 +285,7 @@ class DerivedInterface1(nib.BaseInterface):
278285 input_spec = InputSpec
279286 output_spec = OutputSpec
280287 _version = '0.10'
288+ resource_monitor = False
281289
282290 def _run_interface (self , runtime ):
283291 return runtime
@@ -298,6 +306,7 @@ def test_Commandline():
298306 ci2 = nib .CommandLine (command = 'which' , args = 'ls' )
299307 assert ci2 .cmdline == 'which ls'
300308 ci3 = nib .CommandLine (command = 'echo' )
309+ ci3 .resource_monitor = False
301310 ci3 .inputs .environ = {'MYENV' : 'foo' }
302311 res = ci3 .run ()
303312 assert res .runtime .environ ['MYENV' ] == 'foo'
@@ -312,6 +321,7 @@ class CommandLineInputSpec1(nib.CommandLineInputSpec):
312321 noo = nib .traits .Int (argstr = '-x %d' , desc = 'an int' )
313322 roo = nib .traits .Str (desc = 'not on command line' )
314323 soo = nib .traits .Bool (argstr = "-soo" )
324+
315325 nib .CommandLine .input_spec = CommandLineInputSpec1
316326 ci4 = nib .CommandLine (command = 'cmd' )
317327 ci4 .inputs .foo = 'foo'
0 commit comments