Fix #736: Server repo doesn't end up on any branch after a 'git push'
Added test to make sure we end up on a branch after a push