Skip to content

Commit

Permalink
add check for the seek position
Browse files Browse the repository at this point in the history
  • Loading branch information
glorv committed Sep 6, 2021
1 parent 30f32d1 commit b79e04e
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion br/pkg/storage/s3_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -746,8 +746,9 @@ func (s *s3Suite) TestOpenSeek(c *C) {
offset, err = reader.Seek(p, io.SeekStart)
c.Assert(offset, Equals, int64(1000000))
c.Assert(err, IsNil)
_, err = reader.Read(slice)
pos, err := reader.Read(slice)
c.Assert(err, Equals, io.EOF)
c.Assert(pos, Equals, int64(1000000))
}
}

Expand Down

0 comments on commit b79e04e

Please sign in to comment.