Summary:
Added passing BatchMode option to SSH call only when puchbackup runs in background.
Also fixed dummyssh in skipping options before hostname, added unittest.
Reviewed By: quark-zju
Differential Revision: D7119123
fbshipit-source-id: 2c8e66fee44cca5b23389cba8e21e3a0b237268e
Mercurial assumes that the shell on remote servers over ssh servers uses unix
quoting rules. Tests using dummyssh are however also run on windows where cmd
doesn't parse single quotes like on unix.
This hack replaces the single quotes with double quotes on windows - that is
enough to make test-ssh.t pass after 7bec00a7d7a6.