Fix lint error in e2e_test.go

This commit is contained in:
Ryan Richard 2021-05-12 11:24:00 -07:00
parent 20b86ac0a9
commit 41d3e3b6ec

View File

@ -359,7 +359,7 @@ func TestE2EFullIntegration(t *testing.T) {
}) })
} }
func readFromFileUntilStringIsSeen(t *testing.T, f *os.File, until string) string { func readFromFileUntilStringIsSeen(t *testing.T, f *os.File, until string) {
readFromFile := "" readFromFile := ""
library.RequireEventuallyWithoutError(t, func() (bool, error) { library.RequireEventuallyWithoutError(t, func() (bool, error) {
@ -373,8 +373,6 @@ func readFromFileUntilStringIsSeen(t *testing.T, f *os.File, until string) strin
} }
return false, nil // keep waiting and reading return false, nil // keep waiting and reading
}, 1*time.Minute, 1*time.Second) }, 1*time.Minute, 1*time.Second)
return readFromFile
} }
func readAvailableOutput(t *testing.T, r io.Reader) (string, bool) { func readAvailableOutput(t *testing.T, r io.Reader) (string, bool) {
@ -383,9 +381,8 @@ func readAvailableOutput(t *testing.T, r io.Reader) (string, bool) {
if err != nil { if err != nil {
if err == io.EOF { if err == io.EOF {
return string(buf[:n]), true return string(buf[:n]), true
} else {
require.NoError(t, err)
} }
require.NoError(t, err)
} }
return string(buf[:n]), false return string(buf[:n]), false
} }