mirror of
				https://github.com/nsnail/Ocelot.git
				synced 2025-11-04 15:50:49 +08:00 
			
		
		
		
	test
This commit is contained in:
		@@ -38,6 +38,14 @@
 | 
				
			|||||||
            error.ShouldBeOfType<RequestCanceledError>();
 | 
					            error.ShouldBeOfType<RequestCanceledError>();
 | 
				
			||||||
        }
 | 
					        }
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					        [Fact]
 | 
				
			||||||
 | 
					        public void should_return_request_canceled_for_subtype()
 | 
				
			||||||
 | 
					        {
 | 
				
			||||||
 | 
					            var error = _mapper.Map(new SomeException());
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					            error.ShouldBeOfType<RequestCanceledError>();
 | 
				
			||||||
 | 
					        }
 | 
				
			||||||
 | 
					
 | 
				
			||||||
        [Fact]
 | 
					        [Fact]
 | 
				
			||||||
        public void should_return_error_from_mapper()
 | 
					        public void should_return_error_from_mapper()
 | 
				
			||||||
        {
 | 
					        {
 | 
				
			||||||
@@ -56,5 +64,8 @@
 | 
				
			|||||||
 | 
					
 | 
				
			||||||
            error.ShouldBeOfType<AnyError>();
 | 
					            error.ShouldBeOfType<AnyError>();
 | 
				
			||||||
        }
 | 
					        }
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					        private class SomeException : OperationCanceledException
 | 
				
			||||||
 | 
					        { }
 | 
				
			||||||
    }
 | 
					    }
 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
 
 | 
				
			|||||||
		Reference in New Issue
	
	Block a user