As this is asked in the Criminal forum, I'll assume it's by order of probation/parole pre0sentencing, etc.
Not always. SOmetimes people stand behind you. Sometimes they are next to you, but this can cause "shy bladder." Sometimes there is a curved mirror in front of you, and the person watches from a room behind you, which seems to diminish shy bladder.
If you have shy bladder, tell whoever is supervising you. Sometimes they will let you take a blood test instead.