Skip to content

Commit

Permalink
fix codacy
Browse files Browse the repository at this point in the history
  • Loading branch information
Gramli committed Jun 19, 2024
1 parent f9a6a4f commit 5aa8acb
Showing 1 changed file with 15 additions and 15 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -48,11 +48,11 @@ public async Task AddFileAsync_IOException_All_Failed()
var iFileMockOne = new Mock<IFileProxy>();
var iFileMockTwo = new Mock<IFileProxy>();

var request = new AddFilesCommand(new List<IFileProxy>
{
var request = new AddFilesCommand(
[
iFileMockOne.Object,
iFileMockTwo.Object
});
]);

iFileMockOne.Setup(x => x.GetData(CancellationToken.None)).ThrowsAsync(new IOException());
iFileMockTwo.Setup(x => x.GetData(CancellationToken.None)).ThrowsAsync(new IOException());
Expand All @@ -77,11 +77,11 @@ public async Task AddFileAsync_IOException_One_Failed()
var iFileMockOne = new Mock<IFileProxy>();
var iFileMockTwo = new Mock<IFileProxy>();

var request = new AddFilesCommand(new List<IFileProxy>()
{
var request = new AddFilesCommand(
[
iFileMockOne.Object,
iFileMockTwo.Object
});
]);

iFileMockOne.Setup(x => x.GetData(CancellationToken.None)).ThrowsAsync(new IOException());
iFileMockTwo.Setup(x => x.GetData(CancellationToken.None)).ReturnsAsync(Array.Empty<byte>());
Expand All @@ -108,11 +108,11 @@ public async Task AddFileAsync_All_Failed()
var iFileMockOne = new Mock<IFileProxy>();
var iFileMockTwo = new Mock<IFileProxy>();

var request = new AddFilesCommand(new List<IFileProxy>()
{
var request = new AddFilesCommand(
[
iFileMockOne.Object,
iFileMockTwo.Object
});
]);

iFileMockOne.Setup(x => x.GetData(CancellationToken.None)).ReturnsAsync(Array.Empty<byte>());
iFileMockTwo.Setup(x => x.GetData(CancellationToken.None)).ReturnsAsync(Array.Empty<byte>());
Expand Down Expand Up @@ -141,11 +141,11 @@ public async Task AddFileAsync_One_Failed()
var iFileMockOne = new Mock<IFileProxy>();
var iFileMockTwo = new Mock<IFileProxy>();

var request = new AddFilesCommand(new List<IFileProxy>()
{
var request = new AddFilesCommand(
[
iFileMockOne.Object,
iFileMockTwo.Object
});
]);

iFileMockOne.Setup(x => x.GetData(CancellationToken.None)).ReturnsAsync(Array.Empty<byte>());
iFileMockOne.SetupGet(x => x.FileName).Returns(fileName);
Expand Down Expand Up @@ -175,11 +175,11 @@ public async Task Success()
var iFileMockOne = new Mock<IFileProxy>();
var iFileMockTwo = new Mock<IFileProxy>();

var request = new AddFilesCommand(new List<IFileProxy>()
{
var request = new AddFilesCommand(
[
iFileMockOne.Object,
iFileMockTwo.Object
});
]);

iFileMockOne.Setup(x => x.GetData(CancellationToken.None)).ReturnsAsync(Array.Empty<byte>());
iFileMockTwo.Setup(x => x.GetData(CancellationToken.None)).ReturnsAsync(Array.Empty<byte>());
Expand Down

0 comments on commit 5aa8acb

Please sign in to comment.