Skip to content

Commit ea4f212

Browse files
committed
if interactive reroute consoleout, this fixes vstests swallowing console out
1 parent 8f1023f commit ea4f212

File tree

1 file changed

+6
-1
lines changed

1 file changed

+6
-1
lines changed

build/scripts/Testing.fs

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@ open System
44
open Fake.Core
55
open System.IO
66
open Commandline
7+
open Fake.Core
78
open Versioning
89

910
module Tests =
@@ -52,7 +53,11 @@ module Tests =
5253
| (true) -> [ "--logger"; "trx"; "--collect"; "\"Code Coverage\""; "-v"; "m"] |> List.append command
5354
| _ -> command
5455

55-
Tooling.DotNet.ExecInWithTimeout "src/Tests/Tests" commandWithCodeCoverage (TimeSpan.FromMinutes 30.)
56+
if Environment.UserInteractive && Environment.isWindows then
57+
Tooling.DotNet.ReadInWithTimeout "src/Tests/Tests" commandWithCodeCoverage (TimeSpan.FromMinutes 30.)
58+
|> ignore
59+
else
60+
Tooling.DotNet.ExecInWithTimeout "src/Tests/Tests" commandWithCodeCoverage (TimeSpan.FromMinutes 30.)
5661

5762
let RunReleaseUnitTests (ArtifactsVersion(version)) =
5863
//xUnit always does its own build, this env var is picked up by Tests.csproj

0 commit comments

Comments
 (0)