Skip to content

Commit

Permalink
Fixed test to check for retryCount set in connection string (#2308)
Browse files Browse the repository at this point in the history
  • Loading branch information
lilgreenbird authored Jan 30, 2024
1 parent bb76a78 commit 183426a
Showing 1 changed file with 6 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -275,7 +275,12 @@ public void testAzureEndpointRetry() {
} else if (TestUtils.isAzure(con)) {
assertTrue(retryCount == 2); // AZURE_SERVER_ENDPOINT_RETRY_COUNT_DEFAFULT
} else {
assertTrue(retryCount == 1); // default connectRetryCount
// default retryCount is 1 if not set in connection string
String retryCountFromConnStr = TestUtils.getProperty(connectionString, "connectRetryCount");
int expectedRetryCount = (retryCountFromConnStr != null) ? Integer
.parseInt(retryCountFromConnStr) : 1;

assertTrue(retryCount == expectedRetryCount); // default connectRetryCount
}
}
}
Expand Down

0 comments on commit 183426a

Please sign in to comment.