예제 #1
0
파일: Tests.cs 프로젝트: nateous/XamList
        Task AddContact(string firstName, string lastName, string phoneNumber, bool shouldUseReturnKey)
        {
            ContactsListPage.TapAddContactButton();

            ContactDetailsPage.WaitForPageToLoad();

            ContactDetailsPage.PopulateAllTextFields(firstName, lastName, phoneNumber, shouldUseReturnKey);
            ContactDetailsPage.TapSaveButton();

            ContactsListPage.WaitForPageToLoad();
            return(ContactsListPage.WaitForNoPullToRefreshActivityIndicatorAsync());
        }
예제 #2
0
        public async Task EnterContactInformationThenPressCancel(string firstName, string lastName, string phoneNumber)
        {
            //Arrange

            //Act
            ContactsListPage.TapAddContactButton();

            ContactDetailsPage.WaitForPageToLoad();

            ContactDetailsPage.PopulateAllTextFields(firstName, lastName, phoneNumber, false);
            ContactDetailsPage.TapCancelButton();

            ContactsListPage.WaitForPageToLoad();
            await ContactsListPage.WaitForNoPullToRefreshActivityIndicator().ConfigureAwait(false);

            //Assert
            Assert.IsFalse(ContactsListPage.DoesContactExist(firstName, lastName, phoneNumber));
        }
예제 #3
0
        async Task AddContact(string firstName, string lastName, string phoneNumber, bool shouldUseReturnKey)
        {
            ContactsListPage.TapAddContactButton();

            ContactDetailsPage.WaitForPageToLoad();

            ContactDetailsPage.PopulateAllTextFields(firstName, lastName, phoneNumber, shouldUseReturnKey);
            ContactDetailsPage.TapSaveButton();

            ContactsListPage.WaitForPageToLoad();

            try
            {
                await ContactsListPage.WaitForPullToRefreshActivityIndicator(3).ConfigureAwait(false);
            }
            catch
            {
            }

            await ContactsListPage.WaitForNoPullToRefreshActivityIndicator().ConfigureAwait(false);
        }