Open
Description
def test_check_spectrum_wave_units_errors(t_spectrum):
t_spectrum.spectral_axis = t_spectrum.spectral_axis * u.m # Set incorrect units
with pytest.raises(AstroDBError) as error_message:
check_spectrum_units(t_spectrum, raise_error=True)
assert "Unable to convert spectral axis to microns" in str(error_message)
def test_check_spectrum_flux_units_errors(t_spectrum):