@@ -914,7 +914,7 @@ func TestPreparingProgress(t *testing.T) {
914914 tests .MustPutStore (re , cluster , store )
915915 }
916916 for i := 0 ; i < 100 ; i ++ {
917- tests .MustPutRegion (re , cluster , uint64 (i + 1 ), uint64 (i )% 3 + 1 , []byte (fmt .Sprintf ("p%d " , i )), []byte (fmt .Sprintf ("%d " , i + 1 )), core .SetApproximateSize (10 ))
917+ tests .MustPutRegion (re , cluster , uint64 (i + 1 ), uint64 (i )% 3 + 1 , []byte (fmt .Sprintf ("%20d " , i )), []byte (fmt .Sprintf ("%20d " , i + 1 )), core .SetApproximateSize (10 ))
918918 }
919919 // no store preparing
920920 output := sendRequest (re , leader .GetAddr ()+ "/pd/api/v1/stores/progress?action=preparing" , http .MethodGet , http .StatusNotFound )
@@ -941,8 +941,8 @@ func TestPreparingProgress(t *testing.T) {
941941 re .Equal (math .MaxFloat64 , p .LeftSeconds )
942942
943943 // update size
944- tests .MustPutRegion (re , cluster , 1000 , 4 , []byte (fmt .Sprintf ("%d " , 1000 )), []byte (fmt .Sprintf ("%d " , 1001 )), core .SetApproximateSize (10 ))
945- tests .MustPutRegion (re , cluster , 1001 , 5 , []byte (fmt .Sprintf ("%d " , 1001 )), []byte (fmt .Sprintf ("%d " , 1002 )), core .SetApproximateSize (40 ))
944+ tests .MustPutRegion (re , cluster , 1000 , 4 , []byte (fmt .Sprintf ("%20d " , 1000 )), []byte (fmt .Sprintf ("%20d " , 1001 )), core .SetApproximateSize (10 ))
945+ tests .MustPutRegion (re , cluster , 1001 , 5 , []byte (fmt .Sprintf ("%20d " , 1001 )), []byte (fmt .Sprintf ("%20d " , 1002 )), core .SetApproximateSize (40 ))
946946 time .Sleep (2 * time .Second )
947947 output = sendRequest (re , leader .GetAddr ()+ "/pd/api/v1/stores/progress?action=preparing" , http .MethodGet , http .StatusOK )
948948 re .NoError (json .Unmarshal (output , & p ))
0 commit comments