Should wires be tinned to under the insulation?
NASA, in the NASA Training Program Student Workbook for Hand Soldering, page 9 et seq., say:


  ... adding solder to the wire until the tinning has reached no closer than 0.5 mm (0.020 in.) to insulation.


I think NASA is a reasonably authoritative source for that.

At a guess, I would say that one of the reasons is to avoid embrittlement of, or other undesirable effects on, the insulation. Also, allow the tinning to flow all the way to the insulation could push flux inside - flux should be cleaned off after the soldering operation and that can't be done if it is stuck inside. My suspicion of wire embrittlement through heating looks like it could be unfounded, as thermal strippers can be used to melt insulation to remove it without damaging the wire.

It is desirable to have no stress or strain on the tinned portion of the wire (because tinned wire is more brittle). That can be achieved by clamping the insulation to ~something~. If it is in an environment where there is high vibration and/or thermal cycling, it may or may not be desirable to leave a curve/loop in the wire, but that would require an analysis of the operating environment.

I refer you again to the aforementioned NASA document where they repeatedly refer to "Proper insulation clearance" after making a soldered connection with tinned wire.

If you want insulation over the tinned portion of the wire, you can use heat-shrink tubing. It is available with an adhesive inner coating which is activated when the heat shrink tubing is heat-shrunk, and with the adhesive can provide a watertight seal.

However, Asmyldof points out that:


  The point where the insulation stops over the soldered wire, be it PP, PVC or heatshrink, will become the "focal point" of bending stress. A soldered strand of wire breaks easily. If you leave some length of stranded wire, that length will be the most bendable point in the wire, thus taking the risk somewhat away from the solder. Adding heatshrink to the soldered wire only moves the problem down.


[I changed "room" to "length" in the quote.]

So heatshrink tubing is not a substitute for proper support of the wire.