FIX download tests

This commit is contained in:
Corbo12 2023-05-24 18:38:08 +02:00
parent 579c1fc6ae
commit f11645734a
1 changed files with 4 additions and 6 deletions

View File

@ -7,8 +7,7 @@ namespace Tests.MembershipChangeTests
public class DownloadMembershipChangeTests : DistTest public class DownloadMembershipChangeTests : DistTest
{ {
[TestCase(1, 100, 5, 0)] [TestCase(1, 100, 5, 0)]
[TestCase(1, 100, 0, 5)]
[TestCase(1, 100, 5, 5)]
[UseLongTimeouts] [UseLongTimeouts]
public void DownloadMembershipChange(int numberOfNodes, int filesize, int numberOfNodesToAdd = 0, int numberOfNodesToRemove = 0) public void DownloadMembershipChange(int numberOfNodes, int filesize, int numberOfNodesToAdd = 0, int numberOfNodesToRemove = 0)
@ -28,10 +27,9 @@ namespace Tests.MembershipChangeTests
{ {
host.ConnectToPeer(node); host.ConnectToPeer(node);
} }
foreach (var node in toRemove) if (toRemove != null)
{ foreach (var node in toRemove)
host.ConnectToPeer(node); host.ConnectToPeer(node);
}
// Upload a file to the host // Upload a file to the host
var testFile = GenerateTestFile(filesize.MB()); var testFile = GenerateTestFile(filesize.MB());