Switching to incremental hashing

No longer reading the entire file into memory in order to hash it. Also
adding some basic tests.