Skip to content

Commit

Permalink
fix and test package imports (#334)
Browse files Browse the repository at this point in the history
  • Loading branch information
ntessore authored Oct 7, 2020
1 parent e2b39ce commit 30548c4
Show file tree
Hide file tree
Showing 12 changed files with 36 additions and 5 deletions.
7 changes: 2 additions & 5 deletions skypy/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -13,15 +13,12 @@
# ----------------------------------------------------------------------------

__all__ = []
# from .example_mod import * # noqa
# Then you can be explicit to control what ends up in the namespace,
# __all__ += ['do_primes'] # noqa
# or you can keep everything from the subpackage with the following instead
# __all__ += example_mod.__all__

from . import cluster # noqa
from . import galaxy # noqa
from . import gravitational_wave # noqa
from . import halo # noqa
from . import pipeline # noqa
from . import position # noqa
from . import power_spectrum # noqa
from . import supernova # noqa
2 changes: 2 additions & 0 deletions skypy/cluster/tests/test_import.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
def test_import():
import skypy.cluster
8 changes: 8 additions & 0 deletions skypy/galaxy/tests/test_import.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
def test_import():
import skypy.galaxy
import skypy.galaxy.ellipticity
import skypy.galaxy.luminosity
import skypy.galaxy.redshift
import skypy.galaxy.size
import skypy.galaxy.spectrum
import skypy.galaxy.stellar_mass
2 changes: 2 additions & 0 deletions skypy/gravitational_wave/tests/test_import.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
def test_import():
import skypy.gravitational_wave
5 changes: 5 additions & 0 deletions skypy/halo/tests/test_import.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
def test_import():
import skypy.halo
import skypy.halo.abundance_matching
import skypy.halo.mass
import skypy.halo.quenching
2 changes: 2 additions & 0 deletions skypy/pipeline/tests/test_import.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
def test_import():
import skypy.pipeline
2 changes: 2 additions & 0 deletions skypy/position/tests/test_import.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
def test_import():
import skypy.position
2 changes: 2 additions & 0 deletions skypy/power_spectrum/tests/test_import.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
def test_import():
import skypy.power_spectrum
2 changes: 2 additions & 0 deletions skypy/supernova/tests/test_import.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
def test_import():
import skypy.supernova
2 changes: 2 additions & 0 deletions skypy/tests/test_import.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
def test_import():
import skypy
3 changes: 3 additions & 0 deletions skypy/utils/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,9 @@

__all__ = []

from . import random
from . import special

from ._decorators import (
broadcast_arguments, dependent_argument, uses_default_cosmology,
spectral_data_input)
Expand Down
4 changes: 4 additions & 0 deletions skypy/utils/tests/test_import.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
def test_import():
import skypy.utils
import skypy.utils.random
import skypy.utils.special

0 comments on commit 30548c4

Please sign in to comment.