public void InitializeEnsuresMessageQueueExists() { var mockSurveyTransferQueue = new Mock <IAzureQueue <SurveyTransferMessage> >(); var store = new SurveyTransferStore(mockSurveyTransferQueue.Object); store.Initialize(); mockSurveyTransferQueue.Verify(q => q.EnsureExist()); }
public void TransferAddsMessageToQueue() { var mockSurveyTransferQueue = new Mock <IAzureQueue <SurveyTransferMessage> >(); var store = new SurveyTransferStore(mockSurveyTransferQueue.Object); store.Transfer("tenant", "slugName"); mockSurveyTransferQueue.Verify(q => q.AddMessage(It.Is <SurveyTransferMessage>(m => m.Tenant == "tenant" && m.SlugName == "slugName"))); }
public void InitializeEnsuresMessageQueueExists() { var mockSurveyTransferQueue = new Mock<IAzureQueue<SurveyTransferMessage>>(); var store = new SurveyTransferStore(mockSurveyTransferQueue.Object); store.Initialize(); mockSurveyTransferQueue.Verify(q => q.EnsureExist()); }
public void TransferAddsMessageToQueue() { var mockSurveyTransferQueue = new Mock<IAzureQueue<SurveyTransferMessage>>(); var store = new SurveyTransferStore(mockSurveyTransferQueue.Object); store.Transfer("tenant", "slugName"); mockSurveyTransferQueue.Verify(q => q.AddMessage(It.Is<SurveyTransferMessage>(m => m.Tenant == "tenant" && m.SlugName == "slugName"))); }
public async Task InitializeEnsuresMessageQueueExists() { var mockSurveyTransferQueue = new Mock <IAzureQueue <SurveyTransferMessage> >(); var store = new SurveyTransferStore(mockSurveyTransferQueue.Object); await store.InitializeAsync(); mockSurveyTransferQueue.Verify(q => q.EnsureExistsAsync()); }