Skip to content

Commit ab5efef

Browse files
committed
TEST: Remove clock-tick waits
1 parent dd73d0b commit ab5efef

File tree

1 file changed

+0
-12
lines changed

1 file changed

+0
-12
lines changed

nipype/utils/tests/test_filemanip.py

Lines changed: 0 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,6 @@
55
from builtins import open
66

77
import os
8-
import time
98
from tempfile import mkstemp, mkdtemp
109
import warnings
1110

@@ -20,13 +19,6 @@
2019
import numpy as np
2120

2221

23-
def _wait_for_tick(tic=None):
24-
tic = time.time() if tic is None else tic
25-
toc = time.time()
26-
while int(tic) == int(toc):
27-
toc = time.time()
28-
29-
3022
def _ignore_atime(stat):
3123
return stat[:7] + stat[8:]
3224

@@ -205,11 +197,9 @@ def test_recopy():
205197
if copy and not use_hardlink and hashmethod == 'timestamp':
206198
continue
207199

208-
tic = time.time()
209200
copyfile(orig_img, new_img, **kwargs)
210201
img_stat = _ignore_atime(os.stat(new_img))
211202
hdr_stat = _ignore_atime(os.stat(new_hdr))
212-
_wait_for_tick(tic)
213203
copyfile(orig_img, new_img, **kwargs)
214204
err_msg = "Regular - OS: {}; Copy: {}; Hardlink: {}".format(
215205
os.name, copy, use_hardlink)
@@ -220,11 +210,9 @@ def test_recopy():
220210
os.unlink(new_img)
221211
os.unlink(new_hdr)
222212

223-
tic = time.time()
224213
copyfile(img_link, new_img, **kwargs)
225214
img_stat = _ignore_atime(os.stat(new_img))
226215
hdr_stat = _ignore_atime(os.stat(new_hdr))
227-
_wait_for_tick(tic)
228216
copyfile(img_link, new_img, **kwargs)
229217
err_msg = "Symlink - OS: {}; Copy: {}; Hardlink: {}".format(
230218
os.name, copy, use_hardlink)

0 commit comments

Comments
 (0)