[#13] Client: Use code analyzers
Signed-off-by: Pavel Gross <p.gross@yadro.com>
This commit is contained in:
parent
d7dbbf8da8
commit
d1271df207
102 changed files with 2168 additions and 733 deletions
|
@ -1,14 +1,15 @@
|
|||
using FrostFS.Container;
|
||||
using Google.Protobuf;
|
||||
using Grpc.Core;
|
||||
using Moq;
|
||||
|
||||
using FrostFS.SDK.Cryptography;
|
||||
using FrostFS.SDK.ClientV2;
|
||||
|
||||
using FrostFS.SDK.ClientV2.Mappers.GRPC;
|
||||
using FrostFS.Session;
|
||||
using FrostFS.Refs;
|
||||
using FrostFS.SDK.ClientV2;
|
||||
using FrostFS.SDK.ClientV2.Mappers.GRPC;
|
||||
using FrostFS.SDK.Cryptography;
|
||||
using FrostFS.Session;
|
||||
|
||||
using Google.Protobuf;
|
||||
|
||||
using Grpc.Core;
|
||||
|
||||
using Moq;
|
||||
|
||||
namespace FrostFS.SDK.Tests;
|
||||
|
||||
|
@ -67,8 +68,7 @@ public class ContainerMocker(string key) : ContainerServiceBase(key)
|
|||
{
|
||||
Version = grpcVersion,
|
||||
Nonce = ByteString.CopyFrom(ContainerGuid.ToBytes()),
|
||||
BasicAcl = (uint)Acl,
|
||||
PlacementPolicy = PlacementPolicy.ToMessage()
|
||||
PlacementPolicy = PlacementPolicy.GetPolicy()
|
||||
}
|
||||
},
|
||||
MetaHeader = ResponseMetaHeader
|
||||
|
@ -78,10 +78,10 @@ public class ContainerMocker(string key) : ContainerServiceBase(key)
|
|||
|
||||
var getNoContainerResponse = new GetResponse
|
||||
{
|
||||
Body = new (),
|
||||
Body = new(),
|
||||
MetaHeader = new ResponseMetaHeader
|
||||
{
|
||||
Status = new Status.Status
|
||||
{
|
||||
Status = new Status.Status
|
||||
{
|
||||
Code = 3072,
|
||||
Message = "container not found"
|
||||
|
@ -107,7 +107,7 @@ public class ContainerMocker(string key) : ContainerServiceBase(key)
|
|||
Task.FromResult(ResponseMetaData),
|
||||
() => new Grpc.Core.Status(StatusCode.NotFound, string.Empty),
|
||||
() => ResponseMetaData,
|
||||
() => { });
|
||||
() => { });
|
||||
}
|
||||
|
||||
return new AsyncUnaryCall<GetResponse>(
|
||||
|
@ -115,7 +115,7 @@ public class ContainerMocker(string key) : ContainerServiceBase(key)
|
|||
Task.FromResult(ResponseMetaData),
|
||||
() => new Grpc.Core.Status(StatusCode.OK, string.Empty),
|
||||
() => ResponseMetaData,
|
||||
() => { });
|
||||
() => { });
|
||||
});
|
||||
|
||||
var listResponse = new ListResponse
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue