Fix TestHgBackend test.

Committing to the repository requires a user.

Fixes #667.
Merge pull request #668 from toffer/issue-667-fix-test-hg-backend

Fix TestHgBackend tests.