Skip to content

Commit ac29976

Browse files
authored
Remove a redundant wait-loop in the tests (#444)
Remove a redundant wait-loop in the tests (`AssertDatabaseSize[Async]`); this was *intended* to allow replication catch-up, but the real problem was cluster + FT.* on pre-v8 servers, which is not a supported scenario.
1 parent fe78b2c commit ac29976

File tree

1 file changed

+2
-10
lines changed

1 file changed

+2
-10
lines changed

tests/NRedisStack.Tests/Search/SearchTests.cs

Lines changed: 2 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -55,20 +55,12 @@ private void AddDocument(IDatabase db, string key, Dictionary<string, object> ob
5555

5656
private void AssertDatabaseSize(IDatabase db, int expected)
5757
{
58-
// in part, this is to allow replication to catch up
59-
for (int i = 0; i < 10; i++)
60-
{
61-
Assert.Equal(expected, DatabaseSize(db));
62-
}
58+
Assert.Equal(expected, DatabaseSize(db));
6359
}
6460

6561
private async Task AssertDatabaseSizeAsync(IDatabase db, int expected)
6662
{
67-
// in part, this is to allow replication to catch up
68-
for (int i = 0; i < 10; i++)
69-
{
70-
Assert.Equal(expected, await DatabaseSizeAsync(db));
71-
}
63+
Assert.Equal(expected, await DatabaseSizeAsync(db));
7264
}
7365

7466
[SkipIfRedisTheory(Is.Enterprise)]

0 commit comments

Comments
 (0)