diff options
author | Paul DiPietro <paul.dipietro@me.com> | 2016-04-11 09:50:28 -0700 |
---|---|---|
committer | Jason Smith <jason.smith@xamarin.com> | 2016-04-11 09:50:28 -0700 |
commit | b2ad3e53a8ae03536cf9071b0bd5d0207ee2f10c (patch) | |
tree | 227d1614c84e3d2dbe7f6231276955a6a174ff6d /Xamarin.Forms.Xaml.UnitTests/Issues | |
parent | c0468f1cc33fc4dc415c3a3ca4dc71986b04fc9c (diff) | |
download | xamarin-forms-b2ad3e53a8ae03536cf9071b0bd5d0207ee2f10c.tar.gz xamarin-forms-b2ad3e53a8ae03536cf9071b0bd5d0207ee2f10c.tar.bz2 xamarin-forms-b2ad3e53a8ae03536cf9071b0bd5d0207ee2f10c.zip |
Enable CS0618 warnings as errors (#72)
CS0618 occurs when using an obsolete property or method.
https://msdn.microsoft.com/en-us/library/x5ye6x1e.aspx
Diffstat (limited to 'Xamarin.Forms.Xaml.UnitTests/Issues')
4 files changed, 10 insertions, 0 deletions
diff --git a/Xamarin.Forms.Xaml.UnitTests/Issues/Bz24910.xaml.cs b/Xamarin.Forms.Xaml.UnitTests/Issues/Bz24910.xaml.cs index 50dad4f7..0fa35cc1 100644 --- a/Xamarin.Forms.Xaml.UnitTests/Issues/Bz24910.xaml.cs +++ b/Xamarin.Forms.Xaml.UnitTests/Issues/Bz24910.xaml.cs @@ -102,7 +102,9 @@ namespace Xamarin.Forms.Xaml.UnitTests } public static readonly BindableProperty AttachedNullableIntProperty = +#pragma warning disable 618 BindableProperty.CreateAttached<Bz24910Control, int?> (bindable => GetAttachedNullableInt (bindable), default(int?)); +#pragma warning restore 618 public static int? GetAttachedNullableInt (BindableObject bindable) { diff --git a/Xamarin.Forms.Xaml.UnitTests/Issues/Bz29300.xaml.cs b/Xamarin.Forms.Xaml.UnitTests/Issues/Bz29300.xaml.cs index 3548fc14..3fe04a3f 100644 --- a/Xamarin.Forms.Xaml.UnitTests/Issues/Bz29300.xaml.cs +++ b/Xamarin.Forms.Xaml.UnitTests/Issues/Bz29300.xaml.cs @@ -10,10 +10,14 @@ namespace Xamarin.Forms.Xaml.UnitTests public class Bz29300DummyView : StackLayout { public static readonly BindableProperty NumOfRepeatProperty = +#pragma warning disable 618 BindableProperty.Create<Bz29300DummyView, int> (p => p.NumOfRepeat, 1, BindingMode.OneWay, null, UpdateTexts); +#pragma warning restore 618 public static readonly BindableProperty TextProperty = +#pragma warning disable 618 BindableProperty.Create<Bz29300DummyView, string> (p => p.Text, string.Empty, BindingMode.OneWay, null, UpdateTexts); +#pragma warning restore 618 public int NumOfRepeat { diff --git a/Xamarin.Forms.Xaml.UnitTests/Issues/Issue2742.xaml.cs b/Xamarin.Forms.Xaml.UnitTests/Issues/Issue2742.xaml.cs index ba69280d..00fd6260 100644 --- a/Xamarin.Forms.Xaml.UnitTests/Issues/Issue2742.xaml.cs +++ b/Xamarin.Forms.Xaml.UnitTests/Issues/Issue2742.xaml.cs @@ -38,7 +38,9 @@ namespace Xamarin.Forms.Xaml.UnitTests Assert.NotNull (layout.ToolbarItems); Assert.AreEqual (2, layout.ToolbarItems.Count); +#pragma warning disable 618 Assert.AreEqual ("One", layout.ToolbarItems [0].Name); +#pragma warning restore 618 } } } diff --git a/Xamarin.Forms.Xaml.UnitTests/Issues/TestCases.cs b/Xamarin.Forms.Xaml.UnitTests/Issues/TestCases.cs index ba3c2c2f..04d7ff0d 100644 --- a/Xamarin.Forms.Xaml.UnitTests/Issues/TestCases.cs +++ b/Xamarin.Forms.Xaml.UnitTests/Issues/TestCases.cs @@ -27,7 +27,9 @@ namespace Xamarin.Forms.Xaml.UnitTests } public static readonly BindableProperty InnerViewProperty = +#pragma warning disable 618 BindableProperty.CreateAttached<TestCases, View> (bindable => GetInnerView (bindable), default(View)); +#pragma warning restore 618 public static View GetInnerView (BindableObject bindable) { |