mirror of
https://gitee.com/milvus-io/milvus.git
synced 2026-01-07 19:31:51 +08:00
fix: [2.3] the unstable unit test TestReplicateManager (#29147)
/kind improvement pr: #28718 Signed-off-by: SimFG <bang.fu@zilliz.com>
This commit is contained in:
parent
78865c02e1
commit
c2ce7bce1a
@ -52,7 +52,9 @@ func TestReplicateManager(t *testing.T) {
|
||||
assert.Equal(t, 3, i)
|
||||
res := resourceManager.Delete(ReplicateMsgStreamTyp, "test")
|
||||
assert.NotNil(t, res)
|
||||
time.Sleep(2 * time.Second)
|
||||
assert.Eventually(t, func() bool {
|
||||
return resourceManager.Delete(ReplicateMsgStreamTyp, "test") == nil
|
||||
}, time.Second*4, time.Millisecond*500)
|
||||
|
||||
_, err = manager.GetReplicateMsgStream(context.Background(), "test")
|
||||
assert.NoError(t, err)
|
||||
@ -61,7 +63,9 @@ func TestReplicateManager(t *testing.T) {
|
||||
{
|
||||
res := resourceManager.Delete(ReplicateMsgStreamTyp, "test")
|
||||
assert.NotNil(t, res)
|
||||
time.Sleep(2 * time.Second)
|
||||
assert.Eventually(t, func() bool {
|
||||
return resourceManager.Delete(ReplicateMsgStreamTyp, "test") == nil
|
||||
}, time.Second*4, time.Millisecond*500)
|
||||
|
||||
res, err := resourceManager.Get(ReplicateMsgStreamTyp, "test", func() (resource.Resource, error) {
|
||||
return resource.NewResource(resource.WithObj("str")), nil
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user