File tree Expand file tree Collapse file tree 1 file changed +5
-1
lines changed
src/Cli/dotnet/Commands/Test Expand file tree Collapse file tree 1 file changed +5
-1
lines changed Original file line number Diff line number Diff line change @@ -230,6 +230,11 @@ public static IEnumerable<ParallelizableTestModuleGroupWithSequentialInnerModule
230
230
231
231
string targetFramework = project . GetPropertyValue ( ProjectProperties . TargetFramework ) ;
232
232
RunProperties runProperties = GetRunProperties ( project , loggers ) ;
233
+
234
+ // dotnet run throws the same if RunCommand is null or empty.
235
+ // In dotnet test, we are additionally checking that RunCommand is not dll.
236
+ // In any "default" scenario, RunCommand is never dll.
237
+ // If we found it to be dll, that is user explicitly setting RunCommand incorrectly.
233
238
if ( string . IsNullOrEmpty ( runProperties . RunCommand ) || runProperties . RunCommand . HasExtension ( CliConstants . DLLExtension ) )
234
239
{
235
240
throw new GracefulException (
@@ -238,7 +243,6 @@ public static IEnumerable<ParallelizableTestModuleGroupWithSequentialInnerModule
238
243
"dotnet test" ,
239
244
"OutputType" ,
240
245
project . GetPropertyValue ( "OutputType" ) ) ) ;
241
-
242
246
}
243
247
244
248
string projectFullPath = project . GetPropertyValue ( ProjectProperties . ProjectFullPath ) ;
You can’t perform that action at this time.
0 commit comments