fix flaky fail to ban (#180)
This commit is contained in:
parent
066b6c22d4
commit
e13f8e2a40
1 changed files with 3 additions and 0 deletions
|
|
@ -4,6 +4,7 @@ import (
|
|||
"io"
|
||||
"strings"
|
||||
"testing"
|
||||
"time"
|
||||
)
|
||||
|
||||
func TestFailtoban(t *testing.T) {
|
||||
|
|
@ -76,6 +77,8 @@ func TestFailtoban(t *testing.T) {
|
|||
defer killCmd(c)
|
||||
_ = c.Wait()
|
||||
|
||||
time.Sleep(time.Second) // TODO ugly workaround, wait for stdout flush
|
||||
|
||||
s, _ := io.ReadAll(stdout)
|
||||
|
||||
if !strings.Contains(string(s), "Connection closed by 127.0.0.1") {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue