when the shuffled is true while the testing happens in the test_all_distrs.py and it tests the
test_methods_p it will shuffle the distribution and store the shuffled distribution's object instance in d.
The output from getattr(object_instance,method)(p) will give the output before the distribution is shuffled but when it is checking the output format if indices and columns are matching it is calling _check_output_format(res, d, method).
Solutionres=getattr(object_instance,method)(p) to be replaced with res = getattr(d, method)(p) as this will account for the object_instance after shifting the distribution. This will ensure the outputs are checked with the shifted distribution's instance.
Expected behavior
when the
shuffled
is true while the testing happens in thetest_all_distrs.py
and it tests thetest_methods_p
it will shuffle the distribution and store the shuffled distribution's object instance ind
.The output from
getattr(object_instance,method)(p)
will give the output before the distribution is shuffled but when it is checking the output format if indices and columns are matching it is calling_check_output_format(res, d, method)
.Solution
res=getattr(object_instance,method)(p)
to be replaced withres = getattr(d, method)(p)
as this will account for the object_instance after shifting the distribution. This will ensure the outputs are checked with the shifted distribution's instance.