Skip to content
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 3 additions & 1 deletion eng/pipelines/templates/jobs/sdk-diff-tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -130,11 +130,12 @@ jobs:
echo "##vso[task.setvariable variable=MsftSdkTarballPath]$(Pipeline.Workspace)/Artifacts/$msft_sdk_tarball_name"
echo "##vso[task.setvariable variable=SdkTarballPath]$(Pipeline.Workspace)/Artifacts/$sdk_tarball_name"
echo "##vso[task.setvariable variable=SourceBuiltArtifactsPath]$(Pipeline.Workspace)/Artifacts/$artifacts_path"
echo "##vso[task.setvariable variable=DotNetPath]$_InitializeDotNetCli"
displayName: Prepare Tests
workingDirectory: $(Build.SourcesDirectory)

- script: >
.dotnet/dotnet test
$(DotNetPath)/dotnet test
$(Build.SourcesDirectory)/test/Microsoft.DotNet.SourceBuild.Tests/Microsoft.DotNet.SourceBuild.Tests.csproj
--filter "Category=SdkContent"
--logger:'trx;LogFileName=$(Agent.JobName)_SDKDiffTests.trx'
Expand Down Expand Up @@ -182,6 +183,7 @@ jobs:
- ${{ if and(eq(parameters.publishTestResultsPr, 'true'), or(eq(variables['Build.SourceBranch'], 'refs/heads/main'), startsWith(variables['Build.SourceBranch'], 'refs/heads/release'))) }}:
- template: ../steps/create-baseline-update-pr.yml
parameters:
dotnetPath: $(DotNetPath)
pipeline: sdk
repo: dotnet/dotnet
originalFilesDirectory: test/Microsoft.DotNet.SourceBuild.Tests/assets/SdkContentTests
Expand Down
2 changes: 2 additions & 0 deletions eng/pipelines/templates/stages/vmr-license-scan.yml
Original file line number Diff line number Diff line change
Expand Up @@ -118,6 +118,7 @@ stages:
- script: |
source ./eng/common/tools.sh
InitializeDotNetCli true
echo "##vso[task.setvariable variable=DotNetPath]$_InitializeDotNetCli"
displayName: Install .NET SDK
workingDirectory: $(Build.SourcesDirectory)

Expand All @@ -135,6 +136,7 @@ stages:

- template: /eng/pipelines/templates/steps/create-baseline-update-pr.yml@self
parameters:
dotnetPath: $(DotNetPath)
pipeline: license
repo: dotnet/dotnet
originalFilesDirectory: test/Microsoft.DotNet.SourceBuild.Tests/assets/LicenseScanTests
Expand Down
10 changes: 7 additions & 3 deletions eng/pipelines/templates/stages/vmr-scan.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,11 +16,15 @@ stages:
- script: |
source ./eng/common/tools.sh
InitializeDotNetCli true
.dotnet/dotnet tool restore
displayName: Initialize tooling
echo "##vso[task.setvariable variable=DotNetPath]$_InitializeDotNetCli"
displayName: Install .NET CLI

- script: |
$(DotNetPath)/dotnet tool restore
displayName: Restore tools

- script: >
.dotnet/dotnet darc vmr scan-cloaked-files
$(DotNetPath)/dotnet darc vmr scan-cloaked-files
--vmr "$(Build.SourcesDirectory)"
--tmp "$(Agent.TempDirectory)"
|| (echo '##[error]Found cloaked files in the VMR' && exit 1)
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,8 @@
parameters:
- name: dotnetPath
type: string
default: '$(Build.SourcesDirectory)/.dotnet'

# The pipeline that is being run
# Used to determine the correct baseline update tool to run
# Currently only supports "sdk" and "license"
Expand Down Expand Up @@ -31,7 +35,7 @@ steps:

branchName=$(echo "$(Build.SourceBranch)" | sed 's/refs\/heads\///g')

.dotnet/dotnet run \
$(DotNetPath)/dotnet run \
--project eng/tools/CreateBaselineUpdatePR/ \
--property:RestoreSources="$restoreSources" \
"${{ parameters.pipeline }}" \
Expand Down
Loading