diff options
| author | Rob Mensching <rob@firegiant.com> | 2018-07-13 15:34:43 -0700 |
|---|---|---|
| committer | Rob Mensching <rob@firegiant.com> | 2018-07-13 15:34:43 -0700 |
| commit | ae2f48bb249a9bfa7b509ae4a006faa99bdd6258 (patch) | |
| tree | 525faefc0053d294a537e6f44e289e77fca41d5e /src/test/WixToolsetTest.BuildTasks/FakeBuildEngine.cs | |
| parent | 0a078e422afac38598c026fed3d7abad582e1ddb (diff) | |
| download | wix-ae2f48bb249a9bfa7b509ae4a006faa99bdd6258.tar.gz wix-ae2f48bb249a9bfa7b509ae4a006faa99bdd6258.tar.bz2 wix-ae2f48bb249a9bfa7b509ae4a006faa99bdd6258.zip | |
Add additional debug diagnostics for WixToolsetTest.BuildTasks tests
Diffstat (limited to 'src/test/WixToolsetTest.BuildTasks/FakeBuildEngine.cs')
| -rw-r--r-- | src/test/WixToolsetTest.BuildTasks/FakeBuildEngine.cs | 14 |
1 files changed, 9 insertions, 5 deletions
diff --git a/src/test/WixToolsetTest.BuildTasks/FakeBuildEngine.cs b/src/test/WixToolsetTest.BuildTasks/FakeBuildEngine.cs index 0559057f..8fd69414 100644 --- a/src/test/WixToolsetTest.BuildTasks/FakeBuildEngine.cs +++ b/src/test/WixToolsetTest.BuildTasks/FakeBuildEngine.cs | |||
| @@ -3,11 +3,13 @@ | |||
| 3 | namespace WixToolsetTest.BuildTasks | 3 | namespace WixToolsetTest.BuildTasks |
| 4 | { | 4 | { |
| 5 | using System.Collections; | 5 | using System.Collections; |
| 6 | using System.Diagnostics; | 6 | using System.Text; |
| 7 | using Microsoft.Build.Framework; | 7 | using Microsoft.Build.Framework; |
| 8 | 8 | ||
| 9 | internal class FakeBuildEngine : IBuildEngine | 9 | internal class FakeBuildEngine : IBuildEngine |
| 10 | { | 10 | { |
| 11 | private StringBuilder output = new StringBuilder(); | ||
| 12 | |||
| 11 | public int ColumnNumberOfTaskNode => 0; | 13 | public int ColumnNumberOfTaskNode => 0; |
| 12 | 14 | ||
| 13 | public bool ContinueOnError => false; | 15 | public bool ContinueOnError => false; |
| @@ -16,14 +18,16 @@ namespace WixToolsetTest.BuildTasks | |||
| 16 | 18 | ||
| 17 | public string ProjectFileOfTaskNode => "fake_wix.targets"; | 19 | public string ProjectFileOfTaskNode => "fake_wix.targets"; |
| 18 | 20 | ||
| 21 | public string Output => this.output.ToString(); | ||
| 22 | |||
| 19 | public bool BuildProjectFile(string projectFileName, string[] targetNames, IDictionary globalProperties, IDictionary targetOutputs) => throw new System.NotImplementedException(); | 23 | public bool BuildProjectFile(string projectFileName, string[] targetNames, IDictionary globalProperties, IDictionary targetOutputs) => throw new System.NotImplementedException(); |
| 20 | 24 | ||
| 21 | public void LogCustomEvent(CustomBuildEventArgs e) => Debug.Write(e.Message); | 25 | public void LogCustomEvent(CustomBuildEventArgs e) => this.output.AppendLine(e.Message); |
| 22 | 26 | ||
| 23 | public void LogErrorEvent(BuildErrorEventArgs e) => Debug.Write(e.Message); | 27 | public void LogErrorEvent(BuildErrorEventArgs e) => this.output.AppendLine(e.Message); |
| 24 | 28 | ||
| 25 | public void LogMessageEvent(BuildMessageEventArgs e) => Debug.Write(e.Message); | 29 | public void LogMessageEvent(BuildMessageEventArgs e) => this.output.AppendLine(e.Message); |
| 26 | 30 | ||
| 27 | public void LogWarningEvent(BuildWarningEventArgs e) => Debug.Write(e.Message); | 31 | public void LogWarningEvent(BuildWarningEventArgs e) => this.output.AppendLine(e.Message); |
| 28 | } | 32 | } |
| 29 | } | 33 | } |
