frostfs-sdk-csharp/src/FrostFS.SDK.Tests/Multithread/MultiThreadTestsBase.cs
Pavel Gross 9bb7b5eff8 [] Clients: Make immutable parameters
Signed-off-by: Pavel Gross <p.gross@yadro.com>
2024-12-02 19:33:45 +03:00

42 lines
899 B
C#

using System.Security.Cryptography;
using FrostFS.SDK.Client;
using FrostFS.SDK.Cryptography;
namespace FrostFS.SDK.Tests.Smoke;
public abstract class MultiThreadTestsBase
{
private TestNodeInfo[] nodes;
protected CallContext? Ctx { get; }
protected MultiThreadTestsBase()
{
nodes = new TestNodeInfo[4];
nodes[0] = new(new Uri(""), "");
nodes[1] = new(new Uri(""), "");
nodes[2] = new(new Uri(""), "");
nodes[3] = new(new Uri(""), "");
}
}
public class TestNodeInfo
{
internal Uri Uri;
protected ECDsa? Key { get; }
protected FrostFsOwner? OwnerId { get; }
protected FrostFsVersion? Version { get; }
public TestNodeInfo(Uri uri, string keyString)
{
Uri = uri;
Key = keyString.LoadWif();
OwnerId = FrostFsOwner.FromKey(Key);
Version = new FrostFsVersion(2, 13);
}
}