Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/mono/linker.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSven Boemer <sbomer@gmail.com>2019-04-09 11:14:59 +0300
committerMarek Safar <marek.safar@gmail.com>2019-04-09 11:14:59 +0300
commit84a5611fff0b01ebd014e86904b6ff2240f1314e (patch)
tree727c6077a84d8581356dbf66e90ac9af2703698e /test/Mono.Linker.Tests
parent744804f0a48fe92ebad54eff7d581c9d4af7860d (diff)
Fix IL Compilation tests on .NET Core (#517)
* Fix MissingTargetReference on .NET Core The test was failing because TypeForwarderMissingReference.il depends on mscorlib without a version, and roslyn was looking for Object in mscorlib, Version=0.0.0.0 as a result. This doesn't happen when using csc from the command line because csc uses a different assembly identity comparer by default: DesktopAssemblyIdentityComparer (even on .NET Core). * Also enable CanCompileILAssembly * Also enable UnusedAttributeOnReturnTypeIsRemoved
Diffstat (limited to 'test/Mono.Linker.Tests')
-rw-r--r--test/Mono.Linker.Tests/TestCasesRunner/TestCaseCompiler.cs3
1 files changed, 2 insertions, 1 deletions
diff --git a/test/Mono.Linker.Tests/TestCasesRunner/TestCaseCompiler.cs b/test/Mono.Linker.Tests/TestCasesRunner/TestCaseCompiler.cs
index 75eb965ce..d40db5766 100644
--- a/test/Mono.Linker.Tests/TestCasesRunner/TestCaseCompiler.cs
+++ b/test/Mono.Linker.Tests/TestCasesRunner/TestCaseCompiler.cs
@@ -203,7 +203,8 @@ namespace Mono.Linker.Tests.TestCasesRunner {
{
var parseOptions = new CSharpParseOptions (preprocessorSymbols: options.Defines);
var compilationOptions = new CSharpCompilationOptions (
- outputKind: options.OutputPath.FileName.EndsWith (".exe") ? OutputKind.ConsoleApplication : OutputKind.DynamicallyLinkedLibrary
+ outputKind: options.OutputPath.FileName.EndsWith (".exe") ? OutputKind.ConsoleApplication : OutputKind.DynamicallyLinkedLibrary,
+ assemblyIdentityComparer: DesktopAssemblyIdentityComparer.Default
);
// Default debug info format for the current platform.
DebugInformationFormat debugType = RuntimeInformation.IsOSPlatform (OSPlatform.Windows) ? DebugInformationFormat.Pdb : DebugInformationFormat.PortablePdb;