lib/connections: Trigger dialer when connection gets closed (#7753)

This commit is contained in:
Simon Frei
2021-06-17 13:57:44 +02:00
committed by GitHub
parent aeca1fb575
commit 857caf3637
7 changed files with 231 additions and 68 deletions
+6 -2
View File
@@ -2245,8 +2245,10 @@ func TestSharedWithClearedOnDisconnect(t *testing.T) {
t.Error("not shared with device2")
}
if conn2.Closed() {
select {
case <-conn2.Closed():
t.Error("conn already closed")
default:
}
if _, err := wcfg.RemoveDevice(device2); err != nil {
@@ -2271,7 +2273,9 @@ func TestSharedWithClearedOnDisconnect(t *testing.T) {
}
}
if !conn2.Closed() {
select {
case <-conn2.Closed():
default:
t.Error("connection not closed")
}