Pass base commit IDs during diff validation when posting changes.

Review Request #7017 — Created March 6, 2015 and submitted

Information

RBTools
release-0.7.x
9b7d0c8...

Reviewers

When performing diff validation, we never passed the base commit ID,
which meant that it was impossible to validate against Bitbucket,
Beanstalk, or Unfuddle.

Review Board 2.0.14 will be the first release supporting base commit IDs
in the Diff Validation resource, meaning that we can't rely on the field
being supported. Unfortunately, we also can't tell the base commit ID is
required for a particular diff.

We now check for a new capability for validation and if it's supported,
or if we're not using Git or a base commit ID, then we perform
validation. Otherwise, we fall back to the old behavior of posting and
validating from there.

Posted against RB with the validation resource fix. Saw the call to the
validation resource in the debug output.

Posted against RB without the validation resource fix. The validation
resource was never invoked.

Both tests were against a Bitbucket repository, which I was unable to
post to before. Both tested successfully posted.

reviewbot
  1. Tool: PEP8 Style Checker
    Processed Files:
        rbtools/commands/post.py
        rbtools/api/resource.py
    
    
    
    Tool: Pyflakes
    Processed Files:
        rbtools/commands/post.py
        rbtools/api/resource.py
    
    
  2. 
      
david
  1. Ship It!
  2. 
      
chipx86
Review request changed

Status: Closed (submitted)

Change Summary:

Pushed to release-0.7.x (a30c116)
Loading...