File tree Expand file tree Collapse file tree 4 files changed +38
-11
lines changed Expand file tree Collapse file tree 4 files changed +38
-11
lines changed Original file line number Diff line number Diff line change 33# Packages may add whatever they like to this file, but
44# should keep this content at the top.
55# ----------------------------------------------------------------------------
6- from ._astropy_init import *
6+ from ._astropy_init import * # noqa
77# ----------------------------------------------------------------------------
88
9- from .core import *
9+ from .core import * # noqa
Original file line number Diff line number Diff line change 11# This file is used to configure the behavior of pytest when using the Astropy
22# test infrastructure.
3- import os
4-
53try :
64 from pytest_astropy_header .display import (PYTEST_HEADER_MODULES ,
75 TESTED_VERSIONS )
119
1210# Uncomment the following line to treat all DeprecationWarnings as
1311# exceptions.
14- # from astropy.tests.helper import enable_deprecations_as_exceptions # noqa
12+ # from astropy.tests.helper import enable_deprecations_as_exceptions
1513# enable_deprecations_as_exceptions()
1614
1715# Uncomment and customize the following lines to add/remove entries from
2018# the package uses other astropy affiliated packages.
2119PYTEST_HEADER_MODULES ['Astropy' ] = 'astropy'
2220PYTEST_HEADER_MODULES ['Ginga' ] = 'ginga'
23- PYTEST_HEADER_MODULES .pop ('h5py' )
24- PYTEST_HEADER_MODULES .pop ('Pandas' )
21+ PYTEST_HEADER_MODULES .pop ('h5py' , None )
22+ PYTEST_HEADER_MODULES .pop ('Pandas' , None )
2523
2624# Uncomment the following lines to display the version number of the
2725# package rather than the version number of Astropy in the top line when
2826# running the tests.
2927try :
30- from . version import version
28+ from astrowidgets import __version__ as version
3129except ImportError :
3230 version = 'unknown'
33- packagename = os .path .basename (os .path .dirname (__file__ ))
34- TESTED_VERSIONS [packagename ] = version
31+ TESTED_VERSIONS ['astrowidgets' ] = version
Original file line number Diff line number Diff line change 1+ # This file is used to configure the behavior of pytest when using the Astropy
2+ # test infrastructure.
3+ try :
4+ from pytest_astropy_header .display import (PYTEST_HEADER_MODULES ,
5+ TESTED_VERSIONS )
6+ except ImportError :
7+ PYTEST_HEADER_MODULES = {}
8+ TESTED_VERSIONS = {}
9+
10+ # Uncomment the following line to treat all DeprecationWarnings as
11+ # exceptions.
12+ # from astropy.tests.helper import enable_deprecations_as_exceptions
13+ # enable_deprecations_as_exceptions()
14+
15+ # Uncomment and customize the following lines to add/remove entries from
16+ # the list of packages for which version numbers are displayed when running
17+ # the tests. Making it pass for KeyError is essential in some cases when
18+ # the package uses other astropy affiliated packages.
19+ PYTEST_HEADER_MODULES ['Astropy' ] = 'astropy'
20+ PYTEST_HEADER_MODULES ['Ginga' ] = 'ginga'
21+ PYTEST_HEADER_MODULES .pop ('h5py' , None )
22+ PYTEST_HEADER_MODULES .pop ('Pandas' , None )
23+
24+ # Uncomment the following lines to display the version number of the
25+ # package rather than the version number of Astropy in the top line when
26+ # running the tests.
27+ try :
28+ from astrowidgets import __version__ as version
29+ except ImportError :
30+ version = 'unknown'
31+ TESTED_VERSIONS ['astrowidgets' ] = version
Original file line number Diff line number Diff line change @@ -11,7 +11,6 @@ addopts = -p no:warnings
1111# E501: line too long
1212# W503: line break before binary operator
1313ignore = E501,W503
14- exclude = setup_package.py,conftest.py,__init__.py
1514
1615[metadata]
1716name = astrowidgets
You can’t perform that action at this time.
0 commit comments