Quoted By:
It's not an international border and also not technically a tram, but a light rail line near Karlsruhe has a branch into a research facility that may only be used by employees. The trains stop at the facility's gate and security personnel checks the passengers' worker IDs before continuing into the fenced area.
Also interesting is that the track ends in a stub, while the trains used are unidirectional. So in the morning the trains enter forwards, let passengers deboard and leave the facility empty and backwards to turn around in a loop on the mainline. For the evening trains this happens reversed.