Add test for validating git fetch.
Fix a bunch of test failures due to new git fetch code.