This adds get_entry_by_oid, which returns a hash entry from a tree, based off the oid sha (instead of index or filename, like plain get_entry). I set this as its own method for clarity and especially because this method has different performance characteristics from get_entry; in theory we could fold it into get_entry if we wanted, but I do like this approach for now.
Added three unit tests, confirming correct behavior when given a non-existent oid or when given a non-string argument.
Based on non-trivial differences in performance
between this method and ordinary get_entry, it
has been set as its own method.
Add a test for the nil case