public void Can_convert_DefaultException() { Exception exception = new ModelToExceptionConverter().Convert(new ExceptionModel { Message = "message" }); exception.Should().BeOfType <Exception>(); exception.Message.Should().Be("message"); }
public void Can_convert_InvalidOperationException() { Exception exception = new ModelToExceptionConverter().Convert(new InvalidOperationExceptionModel()); exception.Should().BeOfType <InvalidOperationException>(); }
public void Can_convert_NotSupportedException() { Exception exception = new ModelToExceptionConverter().Convert(new NotSupportedExceptionModel()); exception.Should().BeOfType <NotSupportedException>(); }
public void Can_convert_ArgumentNullExceptionModel() { Exception exception = new ModelToExceptionConverter().Convert(new ArgumentNullExceptionModel()); exception.Should().BeOfType <ArgumentNullException>(); }