summaryrefslogtreecommitdiff
path: root/numpy/lib/tests/test_format.py
diff options
context:
space:
mode:
authorJulian Taylor <jtaylor.debian@googlemail.com>2014-01-14 21:52:34 +0100
committerJulian Taylor <jtaylor.debian@googlemail.com>2014-01-14 21:55:04 +0100
commitbba4ed5398d9b9102d7bd51ebb3ce84a62291c23 (patch)
tree47af0e2a71c891566ee4e165bc86abd6fad87f38 /numpy/lib/tests/test_format.py
parenta4d1e26c56d29fa24cae8570cdedd9d6064679c4 (diff)
downloadnumpy-bba4ed5398d9b9102d7bd51ebb3ce84a62291c23.tar.gz
TST: document reason for truncate instead of seek past end
Diffstat (limited to 'numpy/lib/tests/test_format.py')
-rw-r--r--numpy/lib/tests/test_format.py3
1 files changed, 3 insertions, 0 deletions
diff --git a/numpy/lib/tests/test_format.py b/numpy/lib/tests/test_format.py
index 73b1e7c12..c294637ad 100644
--- a/numpy/lib/tests/test_format.py
+++ b/numpy/lib/tests/test_format.py
@@ -626,6 +626,9 @@ def test_large_file_support():
# try creating a large sparse file
with tempfile.NamedTemporaryFile() as tf:
try:
+ # seek past end would work too, but linux truncate somewhat
+ # increases the chances that we have a sparse filesystem and can
+ # avoid actually writing 5GB
import subprocess as sp
sp.check_call(["truncate", "-s", "5368709120", tf.name])
except: