File tree Expand file tree Collapse file tree 1 file changed +13
-1
lines changed
source/Octopus.Tentacle.Tests.Integration/Support Expand file tree Collapse file tree 1 file changed +13
-1
lines changed Original file line number Diff line number Diff line change @@ -13,6 +13,8 @@ public IntegrationTestTimeout(int timeoutInSeconds) : base((int)TimeSpan.FromSec
1313 public IntegrationTestTimeout() : base(TestTimeoutInMilliseconds())
1414 {
1515 }
16+
17+
1618
1719 public static int TestTimeoutInMilliseconds()
1820 {
@@ -21,7 +23,17 @@ public static int TestTimeoutInMilliseconds()
2123 return (int)TimeSpan.FromHours(1).TotalMilliseconds;
2224 }
2325
24- return (int)TimeSpan.FromMinutes(10).TotalMilliseconds;
26+ return GetTimeoutFromEnvironmentVariable() ?? (int)TimeSpan.FromMinutes(10).TotalMilliseconds;
27+ }
28+
29+ static int? GetTimeoutFromEnvironmentVariable()
30+ {
31+ if (int.TryParse(Environment.GetEnvironmentVariable("IntegrationTest_Timeout_Minutes"), out var timeoutFromEnv))
32+ {
33+ return (int)TimeSpan.FromMinutes(timeoutFromEnv).TotalMilliseconds;
34+ }
35+
36+ return null;
2537 }
2638 }
2739}
You can’t perform that action at this time.
0 commit comments