Seems to me, regardless of the school being informed 'after the event' as some posters are highlighting, that the school is failing pretty badly in its duty in loco parentis to be aware of a pupils circumstances.
Even if it is the families wish for everything to be as normal as possible by keeping the knowledge of an illness out of general circulation, it looks like a gross mishandling of the situation, with compassion superceded by bureaucracy.
The school should have known better in handling this one.
I'm sure there are many good schools out there, but I find it hard to believe that any of the schools I attended would have behaved in such an insensitive and, frankly petty, small minded manner, by imposing such an arbitrary punitive measure.
It shows a lack of foresight, compassion and understanding that, were it not so blatantly obtuse, would be amusing.