Пример #1
0
        public void DeleteFromIndex_MissingContentlink_DoesNotCallDelete()
        {
            _fixture.ServiceLocationMock.IndexerMock.Reset();

            IndexingEvents.DeleteFromIndex(null, null);

            _fixture.ServiceLocationMock.IndexerMock.Verify(m => m.Delete(It.IsAny <ContentReference>()), Times.Never);
        }
Пример #2
0
        public void DeleteFromIndex_ValidContentlink_CallsDelete()
        {
            var input = GetDeleteScenario();

            _fixture.ServiceLocationMock.IndexerMock.Reset();

            IndexingEvents.DeleteFromIndex(null, input.Args);

            _fixture.ServiceLocationMock.IndexerMock.Verify(m => m.Delete(input.Content.ContentLink), Times.Once);
        }