Skip to content

Commit

Permalink
fix bench error
Browse files Browse the repository at this point in the history
  • Loading branch information
roseduan committed Sep 24, 2023
1 parent b73e88f commit 3202245
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions benchmark/bench_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ func init() {
opts := wal.Options{
DirPath: dir,
SegmentFileExt: ".SEG",
SegmentSize: 32 * 1024 * 1024,
SegmentSize: wal.GB,
}
var err error
walFile, err = wal.Open(opts)
Expand Down Expand Up @@ -56,7 +56,7 @@ func BenchmarkWAL_WriteBatch(b *testing.B) {
walFile.PendingWrites([]byte(strings.Repeat("X", wal.MB)))
pos, err := walFile.WriteAll()
assert.Nil(b, err)
assert.Equal(b, 0, len(pos))
assert.Equal(b, 32, len(pos))
}
}

Expand Down

0 comments on commit 3202245

Please sign in to comment.