diff --git a/src/xunit.runner.visualstudio/VsTestRunner.cs b/src/xunit.runner.visualstudio/VsTestRunner.cs index cb0a82d..0e90c05 100644 --- a/src/xunit.runner.visualstudio/VsTestRunner.cs +++ b/src/xunit.runner.visualstudio/VsTestRunner.cs @@ -489,6 +489,10 @@ async Task RunTestsInAssembly( if (assemblyFileName is null) return; + // Pre-enumerate theories by default, so that we can see all traits, including those that come from + // ITheoryDataRow in v3. See: https://github.com/xunit/visualstudio.xunit/issues/426 + runInfo.Assembly.Configuration.PreEnumerateTheories ??= true; + var configuration = runInfo.Assembly.Configuration; using var _ = AssemblyHelper.SubscribeResolveForAssembly(assemblyFileName, new DiagnosticMessageSink(logger, showDiagnostics: configuration.DiagnosticMessagesOrDefault, showInternalDiagnostics: configuration.DiagnosticMessagesOrDefault));