HostingServices can check if SSH keys are associated

Review Request #3478 — Created Nov. 7, 2012 and submitted — Latest diff uploaded

Information

Review Board
master

Reviewers

Automatic SSH key association should only be performed if the key has not
already been associated. HostingServices that support SSH key association
now have the capability to report if a given key has been associated with a
given repository. Currently, only the GitHub HostingService supports SSH
key association.
Added unit test for code that checks if a key has been associated. Made slight adjustment to 
key association test to ensure tests pass (given that a helper method for SSH key association
API calls was added). Both unit tests pass.

Tested manually with an existing GitHub repository by:
    1) adding RB server's (dev server's) SSH key to list of repository deploy keys. Check confirmed 
        key was associated.
    2) adding SSH key to list of user keys. Check confirmed key was associated.
    3) ensuring key NOT associated with repository. Check confirmed key NOT associated.
    4) ensured associate_ssh_key still works as normal for GitHub.
    Loading...