public async Task ThrowNotFoundException() { // Arrange GetSystemLookupQuery query = new GetSystemLookupQuery() { Id = 2 }; // Assert await Assert.ThrowsAsync <NotFoundException> (() => handler.Handle(query, CancellationToken.None)); }
public async Task ReturnSystemLookupViewModelBasedOnIdSuccessfuly() { // Arrange GetSystemLookupQuery query = new GetSystemLookupQuery() { Id = 10 }; // Act var result = await handler.Handle(query, CancellationToken.None); // Assert Assert.IsType <SystemLookupViewModel> (result); }