test: Introduce binary compare function

In msysgit there were some crashes caused by the line conversions
when comparing binary files.

I've also used the patch originally by Stepan Kasal to extend coverage
of binary compares.

Signed-off-by: Michael Geddes <michael@frog.wheelycreek.net>
test: Fix remote failure test to use correct env variable

The test was using the wrong testgit variable helper to cause the failure.
I still don't know why this test wasn't failing on all machines.

Signed-off-by: Michael Geddes <michael@frog.wheelycreek.net>