Fixes for RevisionDiff class, add more test cases.