If you have to substitute and they are trying to leave the door open try for a few minutes and tell them you can't pee.They will either hold you there for a certain amount of time to try again or release you to come back latter.When you come back put a small hose on the quickfix so you can our it in the collection tube without being noticed.
The DOOR is supposed to be closed.Myself I would just try to make like I was trying to piss a couple times and then tell them I just can't piss with people watching.This is NOT a failure of the drug test.