That's not really how it works though. The athlete informs their doctor that they need to comply with WADA. If there is no option but to use a prohibited substance, then the athlete can get a therapeutic exemption for it. Such a case should not result in the athlete 'testing positive'. Testing should have an expectation to find those metabolites. If the athlete has a good faith belief that they were given safe medication, they might be able to plead their case, but otherwise, they basically just ignored their due diligence, which still counts.