Skip to content

Commit fcf624b

Browse files
committed
Revert log() formatting; comment tests [ci skip]
1 parent 60bb7fb commit fcf624b

File tree

2 files changed

+4
-3
lines changed

2 files changed

+4
-3
lines changed

specutils/io/parsing_utils.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -99,8 +99,8 @@ def spectrum_from_column_mapping(table, column_mapping, wcs=None):
9999
kwarg_val = u.Quantity(table[col_name], tab_unit)
100100

101101
# Attempt to convert the table unit to the user-defined unit.
102-
log.debug(f"Attempting auto-convert of table unit {tab_unit} to "
103-
f"user-provided unit {cm_unit}.")
102+
log.debug("Attempting auto-convert of table unit '%s' to "
103+
"user-provided unit '%s'.", tab_unit, cm_unit)
104104

105105
if not isinstance(cm_unit, u.Unit):
106106
cm_unit = u.Unit(cm_unit)

specutils/tests/test_loaders.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -522,6 +522,7 @@ def test_tabular_fits_writer(tmpdir, spectral_axis):
522522
spectrum.write(tmpfile, format='tabular-fits')
523523
spectrum.write(tmpfile, format='tabular-fits', overwrite=True)
524524

525+
# Map to alternative set of units
525526
cmap = {spectral_axis: ('spectral_axis', 'micron'),
526527
'flux': ('flux', 'erg / (s cm**2 AA)'),
527528
'uncertainty': ('uncertainty', None)}
@@ -565,7 +566,7 @@ def test_tabular_fits_multid(tmpdir, ndim, spectral_axis):
565566
assert quantity_allclose(spec.uncertainty.quantity,
566567
spectrum.uncertainty.quantity)
567568

568-
# Test again, using `column_mapping` to convert to different flux unit
569+
# Test again, using `column_mapping` to convert to different spectral axis and flux units
569570
cmap = {spectral_axis: ('spectral_axis', 'THz'),
570571
'flux': ('flux', 'erg / (s cm**2 AA)'),
571572
'uncertainty': ('uncertainty', None)}

0 commit comments

Comments
 (0)