Intercepts test results on the message bus and re-interprets SkipException as a TestSkipped result.
Inheritance: IMessageBus
コード例 #1
0
 /// <inheritdoc />
 public override async Task<RunSummary> RunAsync(IMessageSink diagnosticMessageSink, IMessageBus messageBus, object[] constructorArguments, ExceptionAggregator aggregator, CancellationTokenSource cancellationTokenSource)
 {
     var messageBusInterceptor = new SkippableTestMessageBus(messageBus, this.SkippingExceptionNames);
     var result = await base.RunAsync(diagnosticMessageSink, messageBusInterceptor, constructorArguments, aggregator, cancellationTokenSource);
     result.Failed -= messageBusInterceptor.SkippedCount;
     result.Skipped += messageBusInterceptor.SkippedCount;
     return result;
 }
コード例 #2
0
            /// <inheritdoc />
            public override async Task <RunSummary> RunAsync(IMessageSink diagnosticMessageSink, IMessageBus messageBus, object[] constructorArguments, ExceptionAggregator aggregator, CancellationTokenSource cancellationTokenSource)
            {
                var messageBusInterceptor = new SkippableTestMessageBus(messageBus, this.SkippingExceptionNames);
                var result = await base.RunAsync(diagnosticMessageSink, messageBusInterceptor, constructorArguments, aggregator, cancellationTokenSource);

                result.Failed  -= messageBusInterceptor.SkippedCount;
                result.Skipped += messageBusInterceptor.SkippedCount;
                return(result);
            }