Пример #1
0
 public Task BreakObject()
 {
     return(Mech.BreakAsync(TestObject, new Options
     {
         MaxDuration = 1000,
         DiscoverInheritedMethods = false,
         ExceptionHandlers = new ExceptionHandler().IgnoreException <ArgumentOutOfRangeException>((_, __) => true)
                             .IgnoreException <OutOfMemoryException>((_, __) => true)
                             .IgnoreException <OverflowException>((_, __) => true)
     }));
 }
Пример #2
0
 public Task BreakObject()
 {
     if (TestObject is null)
     {
         return(Task.CompletedTask);
     }
     return(Mech.BreakAsync(TestObject, new Options
     {
         MaxDuration = 1000,
         ExceptionHandlers = new ExceptionHandler()
                             .IgnoreException <NotImplementedException>()
                             .IgnoreException <ArgumentOutOfRangeException>((_, __) => true)
                             .IgnoreException <ArgumentException>()
                             .IgnoreException <ObjectDisposedException>((_, __) => true),
         DiscoverInheritedMethods = false
     }));
 }
Пример #3
0
 public Task BreakObject()
 {
     return(Mech.BreakAsync(TestObject, new Options {
         MaxDuration = 1000
     }));
 }
Пример #4
0
 public Task BreakObject()
 {
     return(Mech.BreakAsync(TestObject));
 }