Skip to content

Commit

Permalink
updates tests
Browse files Browse the repository at this point in the history
  • Loading branch information
LishaRamon committed Dec 4, 2023
1 parent ac052c7 commit 00340db
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions tests/test_data.py
Original file line number Diff line number Diff line change
Expand Up @@ -359,7 +359,7 @@ def test_spectral_types(db):

regime = 'nir'
t = db.query(db.SpectralTypes).filter(db.SpectralTypes.c.regime == regime).astropy()
assert len(t) == 380, f'found {len(t)} spectral types in the {regime} regime'
assert len(t) == 381, f'found {len(t)} spectral types in the {regime} regime'

regime = 'nir_UCD'
t = db.query(db.SpectralTypes).filter(db.SpectralTypes.c.regime == regime).astropy()
Expand All @@ -386,16 +386,16 @@ def test_spectral_types(db):
l_dwarfs = db.query(db.SpectralTypes).filter(
and_(db.SpectralTypes.c.spectral_type_code >= 70,
db.SpectralTypes.c.spectral_type_code < 80)).astropy()
assert len(l_dwarfs) == 1963, f'found {len(t)} L spectral types'
assert len(l_dwarfs) == 1963, f'found {len(l_dwarfs)} L spectral types'

t_dwarfs = db.query(db.SpectralTypes).filter(
and_(db.SpectralTypes.c.spectral_type_code >= 80,
db.SpectralTypes.c.spectral_type_code < 90)).astropy()
assert len(t_dwarfs) == 998, f'found {len(t)} T spectral types'
assert len(t_dwarfs) == 999, f'found {len(t_dwarfs)} T spectral types'

y_dwarfs = db.query(db.SpectralTypes).filter(
and_(db.SpectralTypes.c.spectral_type_code >= 90)).astropy()
assert len(y_dwarfs) == 79, f'found {len(t)} Y spectral types'
assert len(y_dwarfs) == 79, f'found {len(y_dwarfs)} Y spectral types'

n_spectral_types = db.query(db.SpectralTypes).count()
assert len(m_dwarfs) + len(l_dwarfs) + len(t_dwarfs) + len(y_dwarfs) == n_spectral_types
Expand Down

0 comments on commit 00340db

Please sign in to comment.