Skip to content

Commit

Permalink
SNOW-878067: Increase delta for async timeout test
Browse files Browse the repository at this point in the history
  • Loading branch information
sfc-gh-ext-simba-lf committed Oct 26, 2023
1 parent 77611e6 commit 9639f43
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions Snowflake.Data.Tests/IntegrationTests/SFConnectionIT.cs
Original file line number Diff line number Diff line change
Expand Up @@ -1743,12 +1743,12 @@ public void TestAsyncLoginTimeout()

}
stopwatch.Stop();
int detla = 10; //in case server time slower.
int delta = 100; // in case server time slower.

// Should timeout after the minimum possible timeout with jitter: 14 seconds (50% of 4 * 2) after 7 retries
Assert.GreaterOrEqual(stopwatch.ElapsedMilliseconds, 14 * 1000);
// Should timeout before the defined connection timeout
Assert.LessOrEqual(stopwatch.ElapsedMilliseconds, timeoutSec * 1000 + detla);
Assert.LessOrEqual(stopwatch.ElapsedMilliseconds, timeoutSec * 1000 + delta);

Assert.AreEqual(ConnectionState.Closed, conn.State);
Assert.AreEqual(timeoutSec, conn.ConnectionTimeout);
Expand Down

0 comments on commit 9639f43

Please sign in to comment.