namespace Xamarin.Forms.Controls
{
+ [Preserve(AllMembers = true)]
public class ContactsPage : ContentPage
{
public ContactsPage()
}
}
+ [Preserve(AllMembers = true)]
public class ContactViewModel : ViewModelBase2
{
string _name;
}
}
+ [Preserve(AllMembers = true)]
public class Group<TItem> : ObservableCollection<TItem>
{
public Group(string name, IEnumerable<TItem> items)
public string Name { get; set; }
}
+ [Preserve(AllMembers = true)]
public class ViewModelBase2 : INotifyPropertyChanged
{
public event PropertyChangedEventHandler PropertyChanged;
using System.Runtime.CompilerServices;
using System.Text;
using System.Threading.Tasks;
-
using Xamarin.Forms.CustomAttributes;
using Xamarin.Forms.Internals;
+#if UITEST
+using NUnit.Framework;
+#endif
+
namespace Xamarin.Forms.Controls.Issues
{
[Preserve (AllMembers=true)]
[Issue (IssueTracker.Github, 1763, "First item of grouped ListView not firing .ItemTapped", PlatformAffected.WinPhone, NavigationBehavior.PushAsync)]
- public class Issue1763 : TabbedPage
+ public class Issue1763 : TestTabbedPage
{
public Issue1763 ()
{
+
+ }
+
+ protected override void Init()
+ {
Title = "Contacts";
+ Children.Add(new ContactsPage());
+ }
- Children.Add (new ContactsPage ());
+#if UITEST
+ [Test]
+ public void TestIssue1763ItemTappedFiring()
+ {
+ RunningApp.WaitForElement(q => q.Marked("Contacts"));
+ RunningApp.Tap(q => q.Marked("Egor1"));
+ RunningApp.WaitForElement(q => q.Marked("Tapped a List item"));
+ RunningApp.Tap(q => q.Marked("Destruction"));
+ RunningApp.WaitForElement(q => q.Marked("Contacts"));
}
+#endif
+
}
}