-
Notifications
You must be signed in to change notification settings - Fork 418
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #2069 from OmniSharp/feature/better-mono-error-mes…
…sages use an OmniSharp specific message for MSB3644
- v1.39.13
- v1.39.13-beta.32
- v1.39.13-beta.31
- v1.39.13-beta.30
- v1.39.13-beta.28
- v1.39.13-beta.9
- v1.39.12
- v1.39.11
- v1.39.10
- v1.39.9
- v1.39.8
- v1.39.7
- v1.39.6
- v1.39.5
- v1.39.4
- v1.39.3
- v1.39.2
- v1.39.1
- v1.39.0
- v1.38.2
- v1.38.1
- v1.38.0
- v1.37.17
- v1.37.16
- v1.37.15
- v1.37.14
- v1.37.13
- v1.37.12
- v1.37.11
- v1.37.10
- v1.37.9
- v1.37.8
- v1.37.7
Showing
5 changed files
with
51 additions
and
5 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
namespace OmniSharp.MSBuild.Logging | ||
{ | ||
internal class ErrorMessages | ||
{ | ||
internal const string ReferenceAssembliesNotFoundUnix = "This project targets .NET version that requires reference assemblies that do not ship with OmniSharp out of the box (e.g. .NET Framework). The most common solution is to make sure Mono is installed on your machine (https://mono-project.com/download/) and that OmniSharp is started with that Mono installation (e.g. 'omnisharp.useGlobalMono':'always' in C# Extension for VS Code)."; | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
using Microsoft.Build.Framework; | ||
using OmniSharp.MSBuild.Logging; | ||
using OmniSharp.Utilities; | ||
using Xunit; | ||
using Xunit.Abstractions; | ||
|
||
namespace OmniSharp.MSBuild.Tests | ||
{ | ||
public class MSBuildDiagnosticTests : AbstractMSBuildTestFixture | ||
{ | ||
public MSBuildDiagnosticTests(ITestOutputHelper output) : base(output) | ||
{ | ||
} | ||
|
||
[Fact] | ||
public void MSB3644_CustomMessage() | ||
{ | ||
var sourceDiagnostic = new BuildErrorEventArgs("test-subcategory", "MSB3644", "foo.cs", 1, 1, 1, 1, "Reference assemblies not found!", "help-keyword", "dummy-sender"); | ||
var msbuildDiagnostic = MSBuildDiagnostic.CreateFrom(sourceDiagnostic); | ||
|
||
Assert.Equal(Platform.Current.OperatingSystem != OperatingSystem.Windows | ||
? ErrorMessages.ReferenceAssembliesNotFoundUnix : sourceDiagnostic.Message, msbuildDiagnostic.Message); | ||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters