Sorting of git objects & corrections of some tests

Hi,

So I sorted the git objects as mentioned in #25, fixed the cleanup of some tests (due to 8d402fd) and the diff padding in a test of `test_commit`.

Cheers,
Vincent