diff options
author | Jason Smith <jason.smith@xamarin.com> | 2016-03-22 13:02:25 -0700 |
---|---|---|
committer | Jason Smith <jason.smith@xamarin.com> | 2016-03-22 16:13:41 -0700 |
commit | 17fdde66d94155fc62a034fa6658995bef6fd6e5 (patch) | |
tree | b5e5073a2a7b15cdbe826faa5c763e270a505729 /Xamarin.Forms.Controls.Issues/Xamarin.Forms.Controls.Issues.Shared/Bugzilla35738.cs | |
download | xamarin-forms-17fdde66d94155fc62a034fa6658995bef6fd6e5.tar.gz xamarin-forms-17fdde66d94155fc62a034fa6658995bef6fd6e5.tar.bz2 xamarin-forms-17fdde66d94155fc62a034fa6658995bef6fd6e5.zip |
Initial import
Diffstat (limited to 'Xamarin.Forms.Controls.Issues/Xamarin.Forms.Controls.Issues.Shared/Bugzilla35738.cs')
-rw-r--r-- | Xamarin.Forms.Controls.Issues/Xamarin.Forms.Controls.Issues.Shared/Bugzilla35738.cs | 41 |
1 files changed, 41 insertions, 0 deletions
diff --git a/Xamarin.Forms.Controls.Issues/Xamarin.Forms.Controls.Issues.Shared/Bugzilla35738.cs b/Xamarin.Forms.Controls.Issues/Xamarin.Forms.Controls.Issues.Shared/Bugzilla35738.cs new file mode 100644 index 00000000..e79343b3 --- /dev/null +++ b/Xamarin.Forms.Controls.Issues/Xamarin.Forms.Controls.Issues.Shared/Bugzilla35738.cs @@ -0,0 +1,41 @@ +using System; +using System.Diagnostics; +using Xamarin.Forms.CustomAttributes; + +#if UITEST +using Xamarin.UITest; +using NUnit.Framework; +#endif + +namespace Xamarin.Forms.Controls +{ + [Preserve (AllMembers = true)] + public class CustomButton : Button + { + // In the Android project, there's a custom renderer set up for this type + } + + [Preserve (AllMembers = true)] + [Issue (IssueTracker.Bugzilla, 35738, "ButtonRenderer UpdateTextColor function crash", PlatformAffected.Android)] + public class Bugzilla35738 : TestContentPage + { + protected override void Init () + { + var label = new Label () { Text = "If you can see the button, this test has passed" }; + var customButton = new CustomButton () { Text = "This is a custom button", TextColor = Color.Fuchsia }; + + Content = new StackLayout () { + Children = { label, customButton } + }; + } + +#if UITEST + [Test] + [UiTest (typeof(TestContentPage))] + public void CallingOnElementChangedOnCustomButtonShouldNotCrash () + { + RunningApp.WaitForElement (q => q.Marked ("This is a custom button")); + } +#endif + } +}
\ No newline at end of file |