In most jurisdictions, a renovation to an existing building that requires a permit will require that the existing building's subsystems be brought up to current minimum code, to the extent that the renovation relies on that subsystem. For electrical, that means that any wires that are ties into by the electrician must be up to code along the entire circuit all the way back to the panel. If the panel itself doesn't meet code, that must be replaced as well, and in some cases even the wiring out to the pole is the responsibility of the homeowner and thus the electrician doing the work. Plumbing is a little less strict, but many plumbers who find old pipe or code violations will take out as much as is feasible, so they have no worries about what they're tying into. Gas guys, same thing.
Let's say your house is really old, and has some knob & tube wiring. Perfectly safe behind sealed interior walls UNTIL you try to load that circuit beyond 10 amps; then the knobs (which insulate joins and corners of wire runs) heat up, arc, and start fires. Now, the standard is insulated multi-conductor cable, with all wire joins located in fire-rated, accessible junction boxes. It is illegal, ANYWHERE, to simply wire-nut some modern 3-conductor insulated wire to the end of a knob & tube conduit and start using that; the entire run, all the way back to the panel, must be ripped out and replaced with modern 2- or 3-conductor wire in the proper gauge for the required load. Usually, when an electrician catches any hint of knob & tube in a house, he will insist that the entire house's wiring be brought up to code even if he isn't touching any knob & tube himself, because if he knows about it, doesn't do anything about it, and the house burns down, he can be held liable, lose his license and even go to jail even if it wasn't his work that failed.