This commit is contained in:
TomPallister 2020-01-19 17:20:36 +00:00
parent e82e303afc
commit 1723076874

View File

@ -38,6 +38,14 @@
error.ShouldBeOfType<RequestCanceledError>();
}
[Fact]
public void should_return_request_canceled_for_subtype()
{
var error = _mapper.Map(new SomeException());
error.ShouldBeOfType<RequestCanceledError>();
}
[Fact]
public void should_return_error_from_mapper()
{
@ -56,5 +64,8 @@
error.ShouldBeOfType<AnyError>();
}
private class SomeException : OperationCanceledException
{ }
}
}