From 9d8bca92e992eaec03dfb4bcb407dfc61c605c63 Mon Sep 17 00:00:00 2001 From: stijnmoreels <9039753+stijnmoreels@users.noreply.github.com> Date: Fri, 15 Nov 2024 09:05:14 +0100 Subject: [PATCH] pr-fix: add body to put request --- .../Arcus.Scripting.DevOps.tests.ps1 | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/Arcus.Scripting.Tests.Integration/Arcus.Scripting.DevOps.tests.ps1 b/src/Arcus.Scripting.Tests.Integration/Arcus.Scripting.DevOps.tests.ps1 index ae399816..4646a00c 100644 --- a/src/Arcus.Scripting.Tests.Integration/Arcus.Scripting.DevOps.tests.ps1 +++ b/src/Arcus.Scripting.Tests.Integration/Arcus.Scripting.DevOps.tests.ps1 @@ -55,7 +55,8 @@ function global:Remove-AzDevOpsGroupVariable { $upsertVariableGroupUrl = $projectUri + $project + "/_apis/distributedtask/variablegroups/$($json.id)?api-version=7.1" $headers = @{ Authorization = "Bearer $env:SYSTEM_ACCESSTOKEN" } - Write-Host "PUT -> $upsertVariableGroupUrl" + $json = $json | ConvertTo-Json -Depth 10 -Compress + Write-Host "PUT $json -> $upsertVariableGroupUrl" $putResponse = Invoke-WebRequest -Uri $upsertVariableGroupUrl -Method Put -Headers $headers -Body $json -ContentType 'application/json; charset=utf-8' Write-Host "$($putResponse.StatusCode) <- $upsertVariableGroupUrl" }