Skip to content

Commit 090a708

Browse files
authored
Fail Deprecated Xamarin Test Cloud Task (#19474)
* Fail Deprecated Xamarin Test Cloud Task * commit changes to fix test * change feature flag retrieve code * bump task version
1 parent 7198b9a commit 090a708

File tree

11 files changed

+250
-210
lines changed

11 files changed

+250
-210
lines changed

Tasks/XamarinTestCloudV1/Strings/resources.resjson/en-US/resources.resjson

+2-1
Original file line numberDiff line numberDiff line change
@@ -28,5 +28,6 @@
2828
"loc.input.label.optionalArgs": "Optional arguments",
2929
"loc.input.help.optionalArgs": "Additional arguments passed to test-cloud.exe.",
3030
"loc.input.label.publishNUnitResults": "Publish results to Azure Pipelines",
31-
"loc.input.help.publishNUnitResults": "When selected, --nunit-xml option will be passed to test-cloud.exe. Results from the NUnit xml file will be published to Azure Pipelines."
31+
"loc.input.help.publishNUnitResults": "When selected, --nunit-xml option will be passed to test-cloud.exe. Results from the NUnit xml file will be published to Azure Pipelines.",
32+
"loc.messages.DeprecatedTask": "The XamarinTestCloud@1 (Xamarin Test Cloud) task has been deprecated since January 11, 2018 and will soon be retired. Use the AppCenterDistribute@3 task instead."
3233
}

Tasks/XamarinTestCloudV1/XamarinTestCloud.ps1

+7
Original file line numberDiff line numberDiff line change
@@ -193,4 +193,11 @@ if($testCloudResults)
193193
Write-Host "##vso[task.addattachment type=Distributedtask.Core.Summary;name=Xamarin Test Cloud Results;]$mdReportFile"
194194
}
195195

196+
$featureFlags = @{
197+
failDeprecatedBuildTask = [System.Convert]::ToBoolean($env:FAIL_DEPRECATED_BUILD_TASK)
198+
}
199+
if ($featureFlags.failDeprecatedBuildTask)
200+
{
201+
throw "The XamarinTestCloud@1 (Xamarin Test Cloud) task has been deprecated since January 11, 2018 and will soon be retired. Use the AppCenterDistribute@3 task instead."
202+
}
196203
Write-Verbose "Leaving script XamarinTestCloud.ps1"

0 commit comments

Comments
 (0)