For anyone who's legitimately worried about this (or similar) conditions - this is what your school's Technical Standards / Accommodations Committee is for!
Step 1: You jump through the hoops with your University's ADA Office (here, this involves getting your doctor to fill out some forms and sending them to the office).
Step 2: The University ADA Office makes a recommendation (example: We recommend that Student X be allowed frequent restroom breaks).
Step 3: The medical school's Accommodations Committee determines if the proposed accommodations are reasonable, if so, they're approved.
This gives you a vaguely worded letter to give to the relevant people (Course Directors, Attendings, etc) that says something like "Student X is allowed to take frequent restroom breaks due to a disability". At least at our school, the diagnosis is never revealed, and they won't/can't fail you for stepping out to pee (as long as you've given the letter to the appropriate people before it becomes an issue).
Source: I'm on my school's Technical Standards Advisory Committee.