Reset master to testing content
This commit is contained in:
1 parent
0f2587b719
commit
42afa2a56c
1483 files changed
+145308
-938069
No files matched your search
@@ -0,0 +1,20 @@
|
||||
//go:build brlapi && cgo
|
||||
|
||||
package braille
|
||||
|
||||
import "testing"
|
||||
|
||||
func TestNativeClosedLifecycle(t *testing.T) {
|
||||
backend := New()
|
||||
if err := backend.Write("", 0); err == nil {
|
||||
t.Fatal("write on closed connection succeeded")
|
||||
}
|
||||
if _, err := backend.ReadKey(); err == nil {
|
||||
t.Fatal("read on closed connection succeeded")
|
||||
}
|
||||
for range 2 {
|
||||
if err := backend.Close(); err != nil {
|
||||
t.Fatal(err)
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in new issue
Block a user