2
0
mirror of synced 2025-01-21 05:48:59 +00:00

33 lines
846 B
C#
Raw Normal View History

using DistTestCore;
using NUnit.Framework;
namespace ContinuousTests.Tests
{
2023-06-25 10:50:01 +02:00
public class TwoClientTest : ContinuousTest
{
public override int RequiredNumberOfNodes => 2;
2023-08-24 10:44:06 +02:00
public override TimeSpan RunTestEvery => TimeSpan.FromMinutes(1);
2023-06-25 10:50:01 +02:00
public override TestFailMode TestFailMode => TestFailMode.StopAfterFirstFailure;
2023-06-25 10:50:01 +02:00
private ContentId? cid;
private TestFile file = null!;
2023-06-25 10:50:01 +02:00
[TestMoment(t: Zero)]
public void UploadTestFile()
{
file = FileManager.GenerateTestFile(10.MB());
2023-06-25 10:50:01 +02:00
cid = UploadFile(Nodes[0], file);
Assert.That(cid, Is.Not.Null);
}
2023-07-03 08:39:11 +02:00
[TestMoment(t: 10)]
2023-06-25 10:50:01 +02:00
public void DownloadTestFile()
{
2023-06-28 15:11:20 +02:00
var dl = DownloadFile(Nodes[1], cid!);
2023-06-25 10:50:01 +02:00
file.AssertIsEqual(dl);
}
}
}