Skip to content

Commit

Permalink
Increase wait time to stabilize TestRotateDateSuffix (#25869)
Browse files Browse the repository at this point in the history
  • Loading branch information
kvch authored May 26, 2021
1 parent 3a81d81 commit 9e5aafd
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions libbeat/common/file/rotator_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -216,15 +216,15 @@ func TestRotateDateSuffix(t *testing.T) {
firstExpectedPattern := fmt.Sprintf("%s-%s.*", logname, time.Now().Format("20060102150405"))
AssertDirContentsPattern(t, dir, firstExpectedPattern)

time.Sleep(1500 * time.Millisecond)
time.Sleep(2 * time.Second)
secondExpectedPattern := fmt.Sprintf("%s-%s.*", logname, time.Now().Format("20060102150405"))

Rotate(t, r)
WriteMsg(t, r)

AssertDirContentsPattern(t, dir, firstExpectedPattern, secondExpectedPattern)

time.Sleep(1500 * time.Millisecond)
time.Sleep(2 * time.Second)
thirdExpectedPattern := fmt.Sprintf("%s-%s.*", logname, time.Now().Format("20060102150405"))

Rotate(t, r)
Expand Down

0 comments on commit 9e5aafd

Please sign in to comment.