Move require of digest/sha1 to appropriate file

Moved from WithSnapshots to CachedSnapshotFactory.