diff --git a/filebeat/tests/integration/store_test.go b/filebeat/tests/integration/store_test.go index 66c0b14d2e80..c3ddb1ca759c 100644 --- a/filebeat/tests/integration/store_test.go +++ b/filebeat/tests/integration/store_test.go @@ -81,10 +81,8 @@ func TestStore(t *testing.T) { t.Fatalf("could not create logs folder '%s': %s", logsFolder, err) } - logFiles := []string{} for i := 0; i < numLogFiles; i++ { logFile := path.Join(logsFolder, fmt.Sprintf("log-%d.log", i)) - logFiles = append(logFiles, logFile) integration.GenerateLogFile(t, logFile, 10, false) } logsFolderGlob := filepath.Join(logsFolder, "*") diff --git a/libbeat/tests/integration/framework.go b/libbeat/tests/integration/framework.go index 0f26a2e13399..6017c63fd872 100644 --- a/libbeat/tests/integration/framework.go +++ b/libbeat/tests/integration/framework.go @@ -26,7 +26,6 @@ import ( "errors" "fmt" "io" - "io/ioutil" "net/http" "net/url" "os" @@ -525,7 +524,7 @@ func (b *BeatProc) LoadMeta() (Meta, error) { } defer metaFile.Close() - metaBytes, err := ioutil.ReadAll(metaFile) + metaBytes, err := io.ReadAll(metaFile) require.NoError(b.t, err, "error reading meta file") err = json.Unmarshal(metaBytes, &m) require.NoError(b.t, err, "error unmarshalling meta data")