Update mercurial support in tests