Пример #1
0
 def test_setting_fluxes_sets_existing_named_flux_column_if_one_exists(
         self):
     light_curve = LightCurve()
     light_curve.flux_column_names = ['flux_column']
     light_curve.fluxes = [0, 1]
     assert np.array_equal(light_curve.data_frame['flux_column'].values,
                           [0, 1])
Пример #2
0
 def test_fluxes_are_drawn_from_light_curve_data_frame_when_column_names_is_set(
         self):
     light_curve = LightCurve()
     light_curve.data_frame = pd.DataFrame({'flux_column': [0, 1]})
     light_curve.flux_column_names = ['flux_column']
     assert np.array_equal(light_curve.fluxes, [0, 1])