Skip to content

Commit 9d2deba

Browse files
committed
Test reopening a connection.
Signed-off-by: Bradley Grainger <[email protected]>
1 parent 84a5288 commit 9d2deba

File tree

2 files changed

+4
-0
lines changed

2 files changed

+4
-0
lines changed

tests/SideBySide/ConnectAsync.cs

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -74,6 +74,8 @@ public async Task State()
7474
Assert.Equal(ConnectionState.Open, connection.State);
7575
await connection.CloseAsync();
7676
Assert.Equal(ConnectionState.Closed, connection.State);
77+
await connection.OpenAsync();
78+
Assert.Equal(ConnectionState.Open, connection.State);
7779
}
7880

7981
[SkippableFact(ConfigSettings.TcpConnection, Baseline = "https://bugs.mysql.com/bug.php?id=81650")]

tests/SideBySide/ConnectSync.cs

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -159,6 +159,8 @@ public void State()
159159
Assert.Equal(ConnectionState.Open, connection.State);
160160
connection.Close();
161161
Assert.Equal(ConnectionState.Closed, connection.State);
162+
connection.Open();
163+
Assert.Equal(ConnectionState.Open, connection.State);
162164
}
163165

164166
[Fact]

0 commit comments

Comments
 (0)