From d91769a5a381130662683c4937f6ad18d0c7ba61 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Alexander=20K=C3=B6plinger?= Date: Thu, 28 Mar 2019 00:16:53 +0100 Subject: [PATCH] Fix two mmp/mtouch tests after the mcs->csc default change --- tests/mmptest/src/MMPTest.cs | 2 +- tests/mtouch/MTouch.cs | 6 +++--- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/tests/mmptest/src/MMPTest.cs b/tests/mmptest/src/MMPTest.cs index 37ee07a1ee..6691b57b72 100644 --- a/tests/mmptest/src/MMPTest.cs +++ b/tests/mmptest/src/MMPTest.cs @@ -217,7 +217,7 @@ namespace Xamarin.MMP.Tests TI.RunAndAssert ("/Library/Frameworks/Mono.framework/Commands/csc", sb, "b"); File.SetAttributes (assemblyPath, FileAttributes.ReadOnly); - File.SetAttributes (assemblyPath + ".mdb", FileAttributes.ReadOnly); + File.SetAttributes (Path.ChangeExtension (assemblyPath, ".pdb"), FileAttributes.ReadOnly); // build project referencing a.dll TI.UnifiedTestConfig test = new TI.UnifiedTestConfig (tmpDir) diff --git a/tests/mtouch/MTouch.cs b/tests/mtouch/MTouch.cs index e4880db654..4b2f059b4b 100644 --- a/tests/mtouch/MTouch.cs +++ b/tests/mtouch/MTouch.cs @@ -3514,7 +3514,7 @@ public partial class NotificationService : UNNotificationServiceExtension // Create a sample exe var code = "public class TestApp { static void Main () { System.Console.WriteLine (typeof (ObjCRuntime.Runtime).ToString ()); } }"; - var exe = MTouch.CompileTestAppExecutable (tmp, code, "/debug:full"); + var exe = MTouch.CompileTestAppExecutable (tmp, code, "/debug:full", use_csc: false); mtouch.AppPath = mtouch.CreateTemporaryDirectory (); mtouch.RootAssembly = exe; @@ -3531,12 +3531,12 @@ public partial class NotificationService : UNNotificationServiceExtension System.Threading.Thread.Sleep (1000); // HFS does not have sub-second timestamp resolution, so make sure the timestamps actually change... // Recompile the exe, adding only whitespace. This will only change the debug files - MTouch.CompileTestAppExecutable (tmp, "\n\n" + code + "\n\n", "/debug:full"); + MTouch.CompileTestAppExecutable (tmp, "\n\n" + code + "\n\n", "/debug:full", use_csc: false); // Rebuild the app mtouch.AssertExecute (MTouchAction.BuildSim); - // The mdb files should be updated, but the exe should not. + // The pdb files should be updated, but the exe should not. Assert.AreEqual (exeStamp, File.GetLastWriteTimeUtc (exePath), "exe no change"); Assert.IsTrue (File.Exists (mdbPath), "mdb existence"); Assert.AreNotEqual (mdbStamp, File.GetLastWriteTimeUtc (mdbPath), "mdb changed");