localrepo: Add MustWriteBlob helper
Add a helper for writing test blobs in the localrepo. Going forward, this is meant to be the function to use in tests rather than the gittest package.
This will be part of a larger effort to unify executing writing blobs, trees, commits, and tags into a repository from the gittest
package into the localrepo
package, so we have a single package that takes care of writing git objects.