Table of Contents |
---|
SeaLights Pull Request Integration exposes Quality Risks to the developer as part of the Pull Request process, to be displayed and handled before the code is merged into the main branch.
...
The pull request job needs to run the SeaLights build scan and test listener for the test stages you want the analysis on.
These results will be compared to the latest build you reported to SeaLights for the branch you are merging the Pull Request to.
...
The difference between the pull request job and standard jobs is in how the session ID is created using Pull Request specific parameters.
Generating a session ID
You create the Pull Request build session ID by using the SeaLights Java Build Scanner (See: Downloading the java agent files) with the prConfig option:
Code Block | ||||
---|---|---|---|---|
| ||||
java -jar sl-build-scanner.jar -prConfig {-token <arg> | -tokenfile <arg>} -appname <arg>"MyApp" -targetBranch <arg>"master" -latestCommit <arg>pullRequestNumber $GIT_PULL_REQUEST -pullRequestNumber <arg>latestCommit $PULL_REQUEST_SHA -repoUrl <arg>$GIT_REPO_URL [-pi <arg>] [-pe <arg>] |
token
tokenfile
appname
latestCommit
pullRequestNumber
repoUrl
pi, packagesincluded
Comma-separated list of packages to include in scan
Supports wildcards (* = any string, ? = any character). For example: 'com.example.* ,io.*.demo, com.?ello.world'
pe,packagesexcluded
Comma-separated list of packages to exclude from scan
Supports wildcards (* = any string, ? = any character). For example: 'com.example.* ,io.*.demo, com.?ello.world'
proxy
...
tokenfile ./sltoken.txt -pi "*co.sealights.sample.*" |
Note |
---|
The packages included and excluded should be exactly the same as what was defined to SeaLights for the merged branch so that the compared results will be the same |
Info |
---|
See prConfig - Command Reference ' for full parameter details in Java agent, node agent or via the Sealights Jenkins plugin. |
Pull Request parameters explanation as seen in GitHub.com
...