>>2057767I won't pretend it's too common and it's mostly just a temporary switch but it's not completely unheard of. You don't have much open-cut subway construction nowadays either.
Usually however it's just easier to either re-route the tram for a time or run replacement busses. Extensive tram systems will often have service tracks so that trams can be diverted around construction work while still serving most of their route