The big problem is that there is a big grey area between being sick and being unfit to fly.
The last example is a pilot on the first sector of the day , aligned on the runway for take off , shuting down both engine instead of setting the parking brake !!!
Was he sick ? NO Was he fit to fly ? I doubt it
So I am not sure that a doctor will always declare you "sick" even if you are not fit to fly.