fix delay in query execution (#2109)

* fix delay in query execution

* fix test case
This commit is contained in:
Alan Ren
2023-06-19 16:31:47 -07:00
committed by GitHub
parent 6fe0b300e5
commit 7f6b357eb0
3 changed files with 28 additions and 16 deletions

View File

@@ -45,8 +45,8 @@ namespace Microsoft.SqlTools.ServiceLayer.IntegrationTests.Connection
query.Execute();
query.ExecutionTask.Wait();
// We should see two DbConnections
Assert.AreEqual(2, connectionInfo.CountConnections);
// We should see 1 DbConnections
Assert.AreEqual(1, connectionInfo.CountConnections);
// If we run another query
query = new Query(Constants.StandardQuery, connectionInfo, new QueryExecutionSettings(), fileStreamFactory);
@@ -54,7 +54,7 @@ namespace Microsoft.SqlTools.ServiceLayer.IntegrationTests.Connection
query.ExecutionTask.Wait();
// We should still have 2 DbConnections
Assert.AreEqual(2, connectionInfo.CountConnections);
Assert.AreEqual(1, connectionInfo.CountConnections);
// If we disconnect, we should remain in a consistent state to do it over again
// e.g. loop and do it over again