File: src\Microsoft.DotNet.XUnitExtensions.Shared\Discoverers\ParallelTheoryDiscoverer.cs
Web Access
Project: src\src\Microsoft.DotNet.XUnitExtensions\src\Microsoft.DotNet.XUnitExtensions.csproj (Microsoft.DotNet.XUnitExtensions)
// Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
 
// TODO: Not yet supported for xunit.v3
#if !USES_XUNIT_3
using System.Collections.Generic;
using System.Linq;
using System.Threading.Tasks;
 
#if !USES_XUNIT_3
using Xunit.Abstractions;
#endif
using Xunit.Sdk;
 
namespace Microsoft.DotNet.XUnitExtensions
{
    public class ParallelTheoryDiscoverer : TheoryDiscoverer
    {
#if !USES_XUNIT_3
        public ParallelTheoryDiscoverer(IMessageSink diagnosticMessageSink) : base(diagnosticMessageSink)
        {
        }
#endif
        protected override IEnumerable<IXunitTestCase> CreateTestCasesForTheory(ITestFrameworkDiscoveryOptions discoveryOptions, ITestMethod testMethod, IAttributeInfo theoryAttribute)
        {
            return new[] { new XunitParallelTheoryTestCase(DiagnosticMessageSink, discoveryOptions.MethodDisplayOrDefault(), discoveryOptions.MethodDisplayOptionsOrDefault(), testMethod) };
        }
    }
}
#endif