Skip to content

Commit

Permalink
fix test
Browse files Browse the repository at this point in the history
Signed-off-by: yisaer <disxiaofei@163.com>
  • Loading branch information
Yisaer committed May 12, 2021
1 parent 42c2c92 commit bce4c3e
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions server/schedulers/hot_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -672,12 +672,12 @@ func (s *testHotReadRegionSchedulerSuite) TestByteRateOnly(c *C) {
c.Assert(tc.IsRegionHot(tc.GetRegion(1)), IsTrue)
c.Assert(tc.IsRegionHot(tc.GetRegion(11)), IsFalse)
// check randomly pick hot region
r := tc.RandHotRegionFromStore(2, statistics.ReadFlow)
r := tc.HotRegionsFromStore(2, statistics.ReadFlow)
c.Assert(r, NotNil)
c.Assert(r.GetID(), Equals, uint64(2))
c.Assert(len(r), Equals, 3)
// check hot items
stats := tc.HotCache.RegionStats(statistics.ReadFlow, 0)
c.Assert(len(stats), Equals, 2)
c.Assert(len(stats), Equals, 3)
for _, ss := range stats {
for _, s := range ss {
c.Assert(s.GetLoad(statistics.RegionReadBytes), Equals, 512.0*KB)
Expand Down

0 comments on commit bce4c3e

Please sign in to comment.