Honestly, I'm not sure what the right fix is, since I've seen reports that jive with yours, but I'm also seeing your tests break a handful of tests.
Interesting that it breaks other tests. Just reasoning from the code, it should definitely not remove the root-prefix twice. (At least I could not think of a case where this might be useful, except, there is somewhere else a problem which prepends the root twice..)
I'am not sure when I'll find time, but I guess the only way is to debug failing tests with the patch applied.