Allow peeled references without trailing newline at end of file

Also ammends one of the tag tests to make sure it's working. The test now verifies it can read a peeled reference in the middle of the packed-refs file, and at the end without trailing newline.

//cc #1262 #1267