Skip to content

Commit 8dd0e5d

Browse files
committed
Revert "TEST: Check links disabled with config option"
This reverts commit cbf2661.
1 parent 9e05d0d commit 8dd0e5d

File tree

1 file changed

+0
-24
lines changed

1 file changed

+0
-24
lines changed

nipype/utils/tests/test_filemanip.py

Lines changed: 0 additions & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,6 @@
1111
import warnings
1212

1313
import pytest
14-
from ... import config
1514
from ...testing import TempFATFS
1615
from ...utils.filemanip import (save_json, load_json,
1716
fname_presuffix, fnames_presuffix,
@@ -233,29 +232,6 @@ def test_copyfallback(_temp_analyze_files):
233232
os.unlink(tgt_hdr)
234233

235234

236-
def test_symlink_disable(_temp_analyze_files):
237-
tmp = config.getboolean('execution', 'disable_symbolic_links')
238-
assert isinstance(tmp, bool)
239-
config.set('execution', 'disable_symbolic_links', True)
240-
orig_img, orig_hdr = _temp_analyze_files
241-
pth, imgname = os.path.split(orig_img)
242-
pth, hdrname = os.path.split(orig_hdr)
243-
new_img = os.path.join(pth, 'newfile.img')
244-
new_hdr = os.path.join(pth, 'newfile.hdr')
245-
for copy in (True, False):
246-
copyfile(orig_img, new_img, copy=copy, use_hardlink=False)
247-
assert os.path.exists(new_img)
248-
assert os.path.exists(new_hdr)
249-
assert not os.path.islink(new_img)
250-
assert not os.path.islink(new_hdr)
251-
assert not os.path.samefile(orig_img, new_img)
252-
assert not os.path.samefile(orig_hdr, new_hdr)
253-
os.unlink(new_img)
254-
os.unlink(new_hdr)
255-
256-
config.set('execution', 'disable_symbolic_links', tmp)
257-
258-
259235
def test_get_related_files(_temp_analyze_files):
260236
orig_img, orig_hdr = _temp_analyze_files
261237

0 commit comments

Comments
 (0)