Skip to content

Commit

Permalink
tests: Skip if necessary ZIM file isn't present
Browse files Browse the repository at this point in the history
The large ZIM files used for tests are not included in the release
tarball because of their size. But we still want the tests to pass
in that case, so skip if the file is missing.

Fixes #68.
  • Loading branch information
legoktm authored Jul 25, 2020
1 parent b36cc20 commit ff560ea
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions tests/test_libzim_file_reader.py
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,8 @@ def zimdata(request):

@pytest.fixture
def reader(zimdata):
if not zimdata["filename"].exists():
pytest.skip(f"{zimdata['filename']} doesn't exist")
return File(zimdata["filename"])


Expand Down

0 comments on commit ff560ea

Please sign in to comment.