public void TestBaseRepositoryTraceForAfterUpdateAsync() { // Prepare var trace = new Mock <ITrace>(); var repository = new TraceEntityRepository(trace.Object); // Act repository.UpdateAsync( new TraceEntity { Id = 1, Name = "Name" }, whereOrPrimaryKey: 1).Wait(); // Assert trace.Verify(t => t.AfterUpdate(It.IsAny <TraceLog>()), Times.Once); }