Pee in cup every time

Every time I go to my ob/gyn I have to pee in a cup. It's not just me, they do it to everyone as it is their protocol...but I wonder what are they testing for? I always forget to ask. It just seems excessive.