Open rpoleski opened 1 year ago
I've went through output of coverage
code and noted the functions which should be covered better by tests. I know it's a lot of work, but we need such a list to start the work. The list is above.
Implemented in commit 562bc2a
In addition to the unit tests, mentioned above, many lines of event.py are not covered by unittests. I am working on making them more complete.
@rpoleski Line 131 is not covered by unit tests. However, in reviewing the data_ref.setter, I find that data_ref is now always int. So, I think:
Lines 128--131:
if isinstance(self.data_ref, (int)):
data_ref = self.datasets[self.data_ref]
else:
data_ref = self.data_ref
-->
data_ref = self.datasets[self.data_ref]
Agree?
event.py
missing code coverage (wrt commit fa1886b72848768717ae541cd24f2f64bf9027fb):
184-198, plot()
208-254, _plot_lc_default()
260-279, _plot_trajectory_default()
296-300, plot_model()
342-381, plot_data()
394-438, plot_residuals()
446-450, plot_trajectory()
461-467, plot_source_for_datasets()
_set_default_colors()
could be tested.get_ref_fluxes()
warning.567, `fit_blending, deprecated 585, fit_blending, deprecated 613, fit_blending, deprecated 649, fit_blending, deprecated 683, fit_blending, deprecated
calculate_chi2_gradient
, for 1 parameter761-764, _sum()
_set_data_ref()
, new_value = MulensData_set_data_ref()
, duplicate datasets950, comment 984, comment 1016, deprecated 1028, deprecated 1039, deprecated 1043-1052 deprecated
Currently coverage is 72% and we should work on increasing it.
caustics.py
critical_curve()
event.py
__init__()
with fix_source_flux_ratio commit https://github.com/rpoleski/MulensModel/commit/562bc2a0c49bc21f52017640e5abc995fb17edbbevent.py
calculate_chi2_gradient()
with one parameter commit https://github.com/rpoleski/MulensModel/commit/562bc2a0c49bc21f52017640e5abc995fb17edbbevent.py
model()
"if new_value.coords..." commit f413c7eevent.py
source_fluxes()
commit 3b32536fitdata.py
scale_fluxes()
fitdata.py
get_residuals()
and more than 1 sourcefitdata.py
calculate_chi2_gradient()
for 1 parameterfitdata.py
get_dataset_trajectory()
with ephemerides filefitdata.py
_get_d_u_d_params()
fitdata.py
source_flux_ratio()
limbdarkeningcoeffs.py
get_weighted_limb_coeff_gamma()
model.py
set_times()
model.py
set_default_magnification_method()
model.py
get_parallax()
model.py
parameters()
model.py
is_static()
model.py
bandpasses()
modelparameters.py
_get_standard_parameters_from_Cassan08()
modelparameters.py
uniform_caustic_sampling()
mulensdata.py
flux()
mulensdata.py
err_flux()
mulensdata.py
data_and_err_in_chi2_fmt()
mulensdata.py
chi2_fmt()
satelliteskycoord.py
_check_times()
- raise ValueErroruniformcausticsampling.py
_select_n_points()
utils.py
get_y_value_y_err()
utils.py
find_subtract_xlabel()