From 62f0f93c5efe70df97e59617ab581f4e53bd2db7 Mon Sep 17 00:00:00 2001 From: David Federman Date: Fri, 21 Jun 2024 13:31:51 -0700 Subject: [PATCH] Disable the PipelineCaching e2e test for forks --- .azuredevops/pipelines/templates/e2e-test.yml | 3 +++ 1 file changed, 3 insertions(+) diff --git a/.azuredevops/pipelines/templates/e2e-test.yml b/.azuredevops/pipelines/templates/e2e-test.yml index 592fb04..340d8ab 100644 --- a/.azuredevops/pipelines/templates/e2e-test.yml +++ b/.azuredevops/pipelines/templates/e2e-test.yml @@ -15,6 +15,9 @@ steps: - task: PowerShell@2 displayName: "E2E Test: Microsoft.MSBuildCache.AzurePipelines" + # The access token from forks do not have enough scopes to access the pipeline cache, so skip these tests. + # Note to repo maintainers: You can manually run the pipeline against the commit, even if the commit is from a fork, if you wish to test this. + condition: ne(variables['System.PullRequest.IsFork'], 'True') inputs: filePath: ${{ parameters.RepoRoot }}\tests\test.ps1 arguments: -MSBuildPath "${{ parameters.MSBuildPath }}" -Configuration $(BuildConfiguration) -LogDirectory "$(LogDirectory)\Tests\AzurePipelines" -LocalPackageDir "$(Pipeline.Workspace)\artifacts\$(BuildConfiguration)\packages" -CachePackage Microsoft.MSBuildCache.AzurePipelines