Fix a logic error for inserts in the new improved interdiff filter.

Review Request #4222 — Created June 8, 2013 and submitted

Information

Review Board
master

Reviewers

Fix a logic error for inserts in the new improved interdiff filter.

The new interdiff filter had problems dealing inserts in the right-hand
side of an interdiff. The way it was computing whether to switch to the
next range was incorrect. It was considering inserts as equals.

Now it matches the logic on the left-hand side.

A unit test was added based on real interdiff opcodes for a change where
this manifested.

I also noticed that my original test case did in fact have its one and
only right-hand-side insert missing, which was restored after this
change.
Tested with a couple interdiffs I generated locally, based on real-world
diffs from here. Saw that they looked correct and didn't lose the inserts.
reviewbot
  1. This is a review from Review Bot.
      Tool: PEP8 Style Checker
      Processed Files:
        reviewboard/diffviewer/processors.py
        reviewboard/diffviewer/tests.py
      Ignored Files:
    
    
  2. 
      
david
  1. Ship It!
  2. 
      
chipx86
Review request changed

Status: Closed (submitted)

Loading...