Skip to content

Commit a094ce4

Browse files
committed
add regression test
1 parent 02a8de6 commit a094ce4

File tree

2 files changed

+7
-4
lines changed

2 files changed

+7
-4
lines changed

nipype/interfaces/tests/test_auto_JSONFileSink.py

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,10 +3,13 @@
33
from nipype.interfaces.io import JSONFileSink
44

55
def test_JSONFileSink_inputs():
6-
input_map = dict(ignore_exception=dict(nohash=True,
6+
input_map = dict(_outputs=dict(usedefault=True,
7+
),
8+
ignore_exception=dict(nohash=True,
79
usedefault=True,
810
),
9-
in_dict=dict(),
11+
in_dict=dict(usedefault=True,
12+
),
1013
out_file=dict(),
1114
)
1215
inputs = JSONFileSink.input_spec()

nipype/interfaces/tests/test_io.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -259,7 +259,7 @@ def test_jsonsink():
259259
setattr(js.inputs, 'contrasts.alt', 'someNestedValue')
260260
res = js.run()
261261

262-
with open(res.outputs['out_file'], 'r') as f:
262+
with open(res.outputs.out_file, 'r') as f:
263263
data = json.load(f)
264264
yield assert_true, data == {"contrasts": {"alt": "someNestedValue"}, "foo": "var", "new_entry": "someValue"}
265265

@@ -269,7 +269,7 @@ def test_jsonsink():
269269
setattr(js.inputs, 'contrasts.alt', 'someNestedValue')
270270
res = js.run()
271271

272-
with open(res.outputs['out_file'], 'r') as f:
272+
with open(res.outputs.out_file, 'r') as f:
273273
data = json.load(f)
274274
yield assert_true, data == {"test": "testInfields", "contrasts": {"alt": "someNestedValue"}, "foo": "var", "new_entry": "someValue"}
275275

0 commit comments

Comments
 (0)