• 
      

    Add manual trigger run and retry for JenkinsCI integration.

    Review Request #11225 — Created Oct. 15, 2020 and submitted

    Information

    rbintegrations
    master

    Reviewers

    Add manual trigger to JenkinsCI.

    This change adds the ability for Integrations to run JenkinsCI manually.
    A checkbox is added to the JenkinsCI form that indicates if JenkinsCI should
    only run manually.

    The password form label has also been updated to emphasize using an API token
    instead of the user's password since newer versions of Jenkins only works with
    API tokens.

    This change also fixes the Jenkins API failing for Review Board 3 because
    request.open() was not valid.

    Based on work by David Trowbridge: /r/11130

    Manually tested on Review Board 3. Jenkins was set up with Docker and
    connected to a GitHub repository and Review Board 3. A Jenkins build was
    not run when the manually run checkbox is unchecked and is run when the
    field is checked. Clicking on the 'Run' button runs the Jenkins build.

    Verified the disabled/enabled run manually field by testing on Review Board
    3.0.18, 3.0.19 and 4.0.x.

    Verified retry functionality when state is in ERROR and TIMEOUT states.

    Unit tests to verify that a build is not run when the manually run
    configuration is checked and to verify that a build is run when the signal is
    emitted.

    Summary ID
    Add manual trigger and retry to JenkinsCI.
    Refactor Jenkins tests with wrapper spy on function. Add JenkinsCI tests for manual run.
    f75508d87da09be7c63c48fc5a9237da0a77afd0
    Description From Last Updated

    F401 'importlib' imported but unused

    reviewbotreviewbot
    MarcusBoay
    MarcusBoay
    MarcusBoay
    MarcusBoay
    MarcusBoay
    MarcusBoay
    MarcusBoay
    MarcusBoay
    MarcusBoay
    MarcusBoay
    MarcusBoay
    Review request changed
    Change Summary:

    Update based on comments on CircleCI patch

    Commits:
    Summary ID
    Add manual trigger and retry to JenkinsCI.
    Refactor Jenkins tests with wrapper spy on function. Add JenkinsCI tests for manual run.
    658afa3d85686f281623e3681614c074dc8d06e2
    Add manual trigger and retry to JenkinsCI.
    Refactor Jenkins tests with wrapper spy on function. Add JenkinsCI tests for manual run.
    5636794d1dd582e5e815adb07ed0b022c8777cac

    Checks run (1 failed, 1 succeeded)

    flake8 failed.
    JSHint passed.

    flake8

    MarcusBoay
    david
    1. Ship It!
    2. 
        
    MarcusBoay
    Review request changed
    Status:
    Completed
    Change Summary:
    Pushed to release-2.0.x (61cf6b5)