Merge VSTS CI source into Azure Pipelines CI source; add local support for VSTS request source #1416
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This PR provides cleanup and bugfix/enhancement work aimed at improving the level of support for Azure Pipelines. Changes include:
Merging
ci_source/vsts.rb
intoci_source/azure_pipelines.rb
, combining their functionality as appropriate. As was noted as a p.s. on Fix run with Azure Pipelines as CI Source and Azure Repos Git as Request Source #1284, Azure DevOps (which contains Azure Pipelines) is the new name for what used to be Visual Studio Team Services, so these two CI sources were providing two partial implementations for what's actually one CI platform. With this change,azure_pipelines.rb
provides a unified implementation which should support running on Azure DevOps pipelines, with repositories hosted in Azure Devops or elsewhere.Making the changes necessary to support the VSTS request source from a local repository, via
danger pr {pr_url}
. By settingDANGER_VSTS_API_TOKEN
andDANGER_VSTS_HOST
, users can now test against an Azure DevOps pull request locally.Worth noting is that while the VSTS request_source would likely be more appropriately renamed to "AzureGit" or something similar, I held off on making this change only because
DANGER_VSTS_API_TOKEN
andDANGER_VSTS_HOST
reference the "VSTS" nomenclature, and I didn't want to cause a breaking change.