File tree Expand file tree Collapse file tree 2 files changed +7
-7
lines changed Expand file tree Collapse file tree 2 files changed +7
-7
lines changed Original file line number Diff line number Diff line change @@ -28,7 +28,7 @@ def gunzip(filename):
2828 import shutil
2929 import gzip
3030
31- # @EP 09/01/20: system-wide 'gzip' was removed, Python gzip used instead.
31+ # system-wide 'gzip' was removed, Python gzip used instead.
3232 # See #1538 : https://github.com/astropy/astroquery/issues/1538
3333
3434 if not filename .endswith ('.fz' ):
Original file line number Diff line number Diff line change 11# Licensed under a 3-clause BSD style license - see LICENSE.rst
2- """Test `astroquery.utils.system_tools`.
32
4- """
3+ try :
4+ import gzip
5+ HAS_GZIP = True
6+ except ImportError :
7+ HAS_GZIP = False
58
6- # STDLIB
7- import gzip
89import os
910from os .path import exists
1011import tempfile
1112
12- # THIRD-PARTY
1313import pytest
1414
15- # LOCAL
1615from ..system_tools import gunzip
1716
1817
18+ @pytest .mark .skipif ('not HAS_GZIP' )
1919def test_gunzip ():
2020 filehandle = tempfile .NamedTemporaryFile (suffix = '.txt.gz' )
2121 filename = filehandle .name
You can’t perform that action at this time.
0 commit comments