Skip to content

Commit 3e9b996

Browse files
committed
LinkerTests.WarnWithReferenceToPreserveAttribute works
1 parent 099f3c6 commit 3e9b996

File tree

1 file changed

+8
-2
lines changed
  • src/Xamarin.Android.Build.Tasks/Tests/Xamarin.Android.Build.Tests/Tasks

1 file changed

+8
-2
lines changed

src/Xamarin.Android.Build.Tasks/Tests/Xamarin.Android.Build.Tests/Tasks/LinkerTests.cs

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -802,9 +802,15 @@ void Assert64Bit(string rid, bool expected64)
802802
}
803803

804804
[Test]
805-
public void WarnWithReferenceToPreserveAttribute ()
805+
public void WarnWithReferenceToPreserveAttribute ([Values] AndroidRuntime runtime)
806806
{
807-
var proj = new XamarinAndroidApplicationProject { IsRelease = true };
807+
const bool isRelease = true;
808+
if (IgnoreUnsupportedConfiguration (runtime, release: isRelease)) {
809+
return;
810+
}
811+
812+
var proj = new XamarinAndroidApplicationProject { IsRelease = isRelease };
813+
proj.SetRuntime (runtime);
808814
proj.AddReferences ("System.Net.Http");
809815
proj.MainActivity = proj.DefaultMainActivity.Replace (
810816
"protected override void OnCreate",

0 commit comments

Comments
 (0)