Normalize rootPath wherever we find it, with complex tests.