Skip to content

Commit 032caa9

Browse files
committed
Send output to the Console for easier debugging
1 parent dcb75f8 commit 032caa9

File tree

1 file changed

+7
-5
lines changed

1 file changed

+7
-5
lines changed

src/GitVersionCore.Tests/ExecuteCoreTests.cs

Lines changed: 7 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -4,9 +4,7 @@
44
using GitTools.Testing;
55
using GitVersion;
66
using GitVersion.Helpers;
7-
87
using NUnit.Framework;
9-
108
using Shouldly;
119

1210
[TestFixture]
@@ -107,7 +105,7 @@ public void ConfigChangeInvalidatesCache()
107105
fileSystem.WriteAllText(vv.FileName, versionCacheFileContent);
108106
vv = versionAndBranchFinder.ExecuteGitVersion(null, null, null, null, false, fixture.RepositoryPath, null);
109107
vv.AssemblySemVer.ShouldBe("4.10.3.0");
110-
108+
111109
var configPath = Path.Combine(fixture.RepositoryPath, "GitVersionConfig.yaml");
112110
fileSystem.WriteAllText(configPath, "next-version: 5.0");
113111

@@ -121,10 +119,14 @@ string RepositoryScope(ExecuteCore executeCore = null, Action<EmptyRepositoryFix
121119
// Make sure GitVersion doesn't trigger build server mode when we are running the tests
122120
Environment.SetEnvironmentVariable("APPVEYOR", null);
123121
var infoBuilder = new StringBuilder();
124-
Action<string> infoLogger = s => { infoBuilder.AppendLine(s); };
122+
Action<string> infoLogger = s =>
123+
{
124+
infoBuilder.AppendLine(s);
125+
Console.WriteLine(s);
126+
};
125127
executeCore = executeCore ?? new ExecuteCore(fileSystem);
126128

127-
Logger.SetLoggers(infoLogger, s => { }, s => { });
129+
Logger.SetLoggers(infoLogger, Console.WriteLine, Console.WriteLine);
128130

129131
using (var fixture = new EmptyRepositoryFixture())
130132
{

0 commit comments

Comments
 (0)