reverting verify change

This commit is contained in:
Sean Garrett
2023-06-16 22:41:45 +01:00
parent 23780697fb
commit b285c7d919
@@ -197,16 +197,15 @@ public class DeleteManyAsyncTests : TestMongoRepositoryContext
Eraser = new Mock<IMongoDbEraser>(); Eraser = new Mock<IMongoDbEraser>();
Eraser Eraser
.Setup(x => x.DeleteManyAsync<TestDocumentWithKey<int>, int>(documents, cancellationToken)) .Setup(x => x.DeleteManyAsync<TestDocumentWithKey<int>, int>(It.IsAny<IEnumerable<TestDocumentWithKey<int>>>(), It.IsAny<CancellationToken>()))
.ReturnsAsync(count) .ReturnsAsync(count);
.Verifiable();
// Act // Act
var result = await Sut.DeleteManyAsync<TestDocumentWithKey<int>, int>(documents, cancellationToken); var result = await Sut.DeleteManyAsync<TestDocumentWithKey<int>, int>(documents, cancellationToken);
// Assert // Assert
result.Should().Be(count); result.Should().Be(count);
Eraser.Verify(); Eraser.Verify(x => x.DeleteManyAsync<TestDocumentWithKey<int>, int>(documents, cancellationToken), Times.Once);
} }
[Fact] [Fact]