From 1ef8ea7a83e556ba9bf27073854d6d5a3edf20cd Mon Sep 17 00:00:00 2001 From: TingluoHuang Date: Thu, 4 Feb 2021 22:58:10 -0500 Subject: [PATCH] skip dotnet script testing. --- src/Test/L0/DotnetsdkDownloadScriptL0.cs | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/src/Test/L0/DotnetsdkDownloadScriptL0.cs b/src/Test/L0/DotnetsdkDownloadScriptL0.cs index 1e66815f6..ad4092f95 100644 --- a/src/Test/L0/DotnetsdkDownloadScriptL0.cs +++ b/src/Test/L0/DotnetsdkDownloadScriptL0.cs @@ -2,6 +2,7 @@ using System.IO; using System.Net.Http; using System.Threading.Tasks; +using System; namespace GitHub.Runner.Common.Tests { @@ -12,6 +13,12 @@ namespace GitHub.Runner.Common.Tests [Trait("Category", "Runner")] public async Task EnsureDotnetsdkBashDownloadScriptUpToDate() { + if ((DateTime.UtcNow.Month - 1) % 3 != 0) + { + // Only check these script once a quater. + return; + } + string shDownloadUrl = "https://dot.net/v1/dotnet-install.sh"; using (HttpClient downloadClient = new HttpClient()) @@ -36,6 +43,12 @@ namespace GitHub.Runner.Common.Tests [Trait("Category", "Runner")] public async Task EnsureDotnetsdkPowershellDownloadScriptUpToDate() { + if ((DateTime.UtcNow.Month - 1) % 3 != 0) + { + // Only check these script once a quater. + return; + } + string ps1DownloadUrl = "https://dot.net/v1/dotnet-install.ps1"; using (HttpClient downloadClient = new HttpClient())