Skip to content

Commit 0ae799d

Browse files
committed
fix reference DESCR length for YiiP test
The YiiP test failed locally for me. I adjusted the reference number of characters in the DESCR file (same as with wc) but because these tests are NOT run in CI, I am not 100% sure if this is correct or a local issue. I added comments to test_datasets.py about limitations and how to execute locally.
1 parent 25f3921 commit 0ae799d

1 file changed

Lines changed: 13 additions & 1 deletion

File tree

MDAnalysisData/tests/test_datasets.py

Lines changed: 13 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,6 +27,18 @@
2727
# For filetype=topology, the data are downloaded and cached.
2828
# For filetype=trajectory the cached data are used.
2929
# This test is not thread/parallel safe.
30+
#
31+
# These tests are not enabled by default and are only executed with
32+
# `pytest -m online` or `pytest --pyargs MDAnalysisData` because they
33+
# require downloading datasets.
34+
35+
# CURRENT LIMITATIONS:
36+
#
37+
# Assertions related to DESCR will currently only pass on UNIX (and
38+
# not Windows) because of different line ending conventions (UNIX: \n,
39+
# Windows:\r\n); the tests could be rewritten (e.g., use
40+
# `DESCR.split()` to compare words) and using regex for matching the
41+
# first lines.
3042

3143
@pytest.mark.online
3244
@pytest.mark.parametrize('filetype', ('topology', 'trajectory'))
@@ -159,7 +171,7 @@ def test_yiip_equilibrium(traj_len, filetype):
159171

160172
metadata = yiip_equilibrium.ARCHIVE[traj_len]
161173

162-
assert len(data.DESCR) == 1511
174+
assert len(data.DESCR) == 1536
163175
assert data.DESCR.startswith(".. -*- coding: utf-8 -*-\n\n.. _`yiip-equilibrium-dataset`:")
164176

165177
assert os.path.basename(data[filetype]) == metadata[filetype].filename

0 commit comments

Comments
 (0)