Skip to content

Commit 5ffe001

Browse files
authored
Split thresholds for Windows and Linux JITTraces release tests. (#7616)
1 parent e08ae5b commit 5ffe001

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

test/WebJobs.Script.Tests.Integration/PreJIT/JitPreparesTest.cs

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -16,9 +16,9 @@ namespace Microsoft.Azure.WebJobs.Script.Tests.PreJIT
1616
public class JitPreparesTest
1717
{
1818
[Theory]
19-
[InlineData(WarmUpConstants.JitTraceFileName)]
20-
[InlineData(WarmUpConstants.LinuxJitTraceFileName)]
21-
public void ColdStart_JitFailuresTest(string fileName)
19+
[InlineData(WarmUpConstants.JitTraceFileName, 1.0)]
20+
[InlineData(WarmUpConstants.LinuxJitTraceFileName, 3.0)]
21+
public void ColdStart_JitFailuresTest(string fileName, double threshold)
2222
{
2323
var path = Path.Combine(Path.GetDirectoryName(new Uri(typeof(HostWarmupMiddleware).Assembly.CodeBase).LocalPath), WarmUpConstants.PreJitFolderName, fileName);
2424

@@ -31,7 +31,7 @@ public void ColdStart_JitFailuresTest(string fileName)
3131
var failurePercentage = (double)failedPrepares / successfulPrepares * 100;
3232

3333
// using 1% as approximate number of allowed failures before we need to regenrate a new PGO file.
34-
Assert.True(failurePercentage < 1.0, $"Number of failed PGOs are more than 1 percent! Current number of failures are {failedPrepares}. This will definitely impact cold start! Time to regenrate PGOs and update the {fileName} file!");
34+
Assert.True(failurePercentage < threshold, $"Number of failed PGOs are more than {threshold} percent! Current number of failures are {failedPrepares}. This will definitely impact cold start! Time to regenrate PGOs and update the {fileName} file!");
3535
}
3636
}
3737
}

0 commit comments

Comments
 (0)