Esempio n. 1
0
        public void Filter_Using_Organization_Type()
        {
            LeftSideMenu.GoToOrganizations();
            OrganizationsPage.FilterBy().SelectingAccountType(AccountType.Consultant).Filter();
            int expectedResult1 = 0;

            VerifyThat.AreEqual(OrganizationsPage.TotalOrganizationsCountByLabel, expectedResult1, $"The sum of organizations being displayed with Account Type = {AccountType.Consultant} is different from the expected. OrganizationsDisplayed={OrganizationsPage.TotalOrganizationsCountByLabel}, Expected={expectedResult1}");

            OrganizationsPage.ResetFilters();
            OrganizationsPage.FilterBy().SelectingAccountType(AccountType.Reseller).Filter();
            int expectedResult2 = 10;

            VerifyThat.AreEqual(OrganizationsPage.TotalOrganizationsCountByLabel, expectedResult2, $"The sum of organizations being displayed with Account Type = {AccountType.Reseller} is different from the expected. OrganizationsDisplayed={OrganizationsPage.TotalOrganizationsCountByLabel}, Expected={expectedResult2}");

            OrganizationsPage.ResetFilters();
            OrganizationsPage.FilterBy().SelectingAccountType(AccountType.Customer).Filter();
            int expectedResult3 = 82;

            VerifyThat.AreEqual(OrganizationsPage.TotalOrganizationsCountByLabel, expectedResult3, $"The sum of organizations being displayed with Account Type = {AccountType.Customer} is different from the expected. OrganizationsDisplayed={OrganizationsPage.TotalOrganizationsCountByLabel}, Expected={expectedResult3}");

            OrganizationsPage.ResetFilters();
            OrganizationsPage.FilterBy().SelectingAccountType(AccountType.Supplier).Filter();
            int expectedResult4 = 7;

            VerifyThat.AreEqual(OrganizationsPage.TotalOrganizationsCountByLabel, expectedResult4, $"The sum of organizations being displayed with Account Type = {AccountType.Supplier} is different from the expected. OrganizationsDisplayed={OrganizationsPage.TotalOrganizationsCountByLabel}, Expected={expectedResult4}");

            OrganizationsPage.ResetFilters();
            OrganizationsPage.FilterBy().SelectingAccountType(AccountType.Partner).Filter();
            int expectedResult5 = 1;

            VerifyThat.AreEqual(OrganizationsPage.TotalOrganizationsCountByLabel, expectedResult5, $"The sum of organizations being displayed with Account Type = {AccountType.Partner} is different from the expected. OrganizationsDisplayed={OrganizationsPage.TotalOrganizationsCountByLabel}, Expected={expectedResult5}");
        }
Esempio n. 2
0
        public void Filter_Organizations_With_SearchBox()
        {
            LeftSideMenu.GoToOrganizations();
            OrganizationsPage.FindOrganization().ContainingKeyword("koro").Find();
            int expectedResult1 = 2;

            VerifyThat.AreEqual(OrganizationsPage.TotalOrganizationsCountByLabel, expectedResult1, $"Search using organization name field, with keyword = 'koro', doesn't work. The sum of contacts being displayed is different from the expected. ContactsDisplayed={OrganizationsPage.TotalOrganizationsCountByLabel}, Expected={expectedResult1}");

            OrganizationsPage.FindOrganization().ContainingKeyword("21066").Find();
            int expectedResult2 = 3;

            VerifyThat.AreEqual(OrganizationsPage.TotalOrganizationsCountByLabel, expectedResult2, $"Search using phone field, with keyword = '21066', doesn't work. The sum of contacts being displayed is different from the expected. ContactsDisplayed={OrganizationsPage.TotalOrganizationsCountByLabel}, Expected={expectedResult2}");

            OrganizationsPage.FindOrganization().ContainingKeyword("@la").Find();
            int expectedResult3 = 6;

            VerifyThat.AreEqual(OrganizationsPage.TotalOrganizationsCountByLabel, expectedResult3, $"Search using website name field, with keyword = '@la', doesn't work. The sum of contacts being displayed is different from the expected. ContactsDisplayed={OrganizationsPage.TotalOrganizationsCountByLabel}, Expected={expectedResult3}");

            OrganizationsPage.FindOrganization().ContainingKeyword("γο").Find();
            int expectedResult4 = 3;

            VerifyThat.AreEqual(OrganizationsPage.TotalOrganizationsCountByLabel, expectedResult4, $"Search using street name field, with keyword = 'γο', doesn't work. The sum of contacts being displayed is different from the expected. ContactsDisplayed={OrganizationsPage.TotalOrganizationsCountByLabel}, Expected={expectedResult4}");

            OrganizationsPage.FindOrganization().ContainingKeyword("Καλλιθε").Find();
            int expectedResult5 = 4;

            VerifyThat.AreEqual(OrganizationsPage.TotalOrganizationsCountByLabel, expectedResult5, $"Search using city name field, with keyword = 'Καλλιθε', doesn't work. The sum of contacts being displayed is different from the expected. ContactsDisplayed={OrganizationsPage.TotalOrganizationsCountByLabel}, Expected={expectedResult5}");
        }
Esempio n. 3
0
        public void Search_Using_Searchbox()
        {
            CoworkersPage.FindCoworker().ContainingKeyword("γιάννης").Find();
            int expectedResult1 = 3;

            VerifyThat.AreEqual(CoworkersPage.TotalCoworkersCount, expectedResult1,
                                $"Search using first name field, with keyword = 'γιάννης', doesn't work. The sum of contacts being displayed is different from the expected. ContactsDisplayed={CoworkersPage.TotalCoworkersCount}, Expected={expectedResult1}");

            CoworkersPage.FindCoworker().ContainingKeyword("Γιωργος").Find();
            int expectedResult2 = 3;

            VerifyThat.AreEqual(CoworkersPage.TotalCoworkersCount, expectedResult2,
                                $"Search using first name field, with keyword = 'Γιωργος', doesn't work. The sum of contacts being displayed is different from the expected. ContactsDisplayed={CoworkersPage.TotalCoworkersCount}, Expected={expectedResult2}");

            CoworkersPage.FindCoworker().ContainingKeyword("research").Find();
            int expectedResult3 = 1;

            VerifyThat.AreEqual(CoworkersPage.TotalCoworkersCount, expectedResult3,
                                $"Search using department field, with keyword = 'research', doesn't work. The sum of contacts being displayed is different from the expected. ContactsDisplayed={CoworkersPage.TotalCoworkersCount}, Expected={expectedResult3}");

            CoworkersPage.FindCoworker().ContainingKeyword("13332423").Find();
            int expectedResult4 = 1;

            VerifyThat.AreEqual(CoworkersPage.TotalCoworkersCount, expectedResult4,
                                $"Search using mobile phone field, with keyword = '13332423', doesn't work. The sum of contacts being displayed is different from the expected. ContactsDisplayed={CoworkersPage.TotalCoworkersCount}, Expected={expectedResult4}");

            CoworkersPage.FindCoworker().ContainingKeyword("koko").Find();
            int expectedResult5 = 1;

            VerifyThat.AreEqual(CoworkersPage.TotalCoworkersCount, expectedResult5,
                                $"Search using email field, with keyword = 'koko', doesn't work. The sum of contacts being displayed is different from the expected. ContactsDisplayed={CoworkersPage.TotalCoworkersCount}, Expected={expectedResult5}");
        }
Esempio n. 4
0
        public void Search_Using_Side_Alphabet_Bar()
        {
            LeftSideMenu.GoToOrganizations();

            AlphabetSideBar.SelectLetter(LatinAlphabet.RestChars);
            int expectedResult1 = 0;

            VerifyThat.AreEqual(ContactsPage.TotalContactsCountByLabel, expectedResult1, $"Alphabet side bar doesn't work. The sum of contacts being displayed is different from the expected. ContactsDisplayed={ContactsPage.TotalContactsCount}, Expected={expectedResult1}");

            AlphabetSideBar.SelectLetter(LatinAlphabet.Z);
            int expectedResult2 = 0;

            VerifyThat.AreEqual(ContactsPage.TotalContactsCountByLabel, expectedResult2, $"Alphabet side bar doesn't work. The sum of contacts being displayed is different from the expected. ContactsDisplayed={ContactsPage.TotalContactsCount}, Expected={expectedResult2}");

            AlphabetSideBar.SelectLetter(LatinAlphabet.L);
            int expectedResult3 = 93;

            VerifyThat.AreEqual(ContactsPage.TotalContactsCountByLabel, expectedResult3, $"Alphabet side bar doesn't work. The sum of contacts being displayed is different from the expected. ContactsDisplayed={ContactsPage.TotalContactsCount}, Expected={expectedResult3}");

            AlphabetSideBar.SelectLetter(GreekAlphabet.RestChars);
            int expectedResult4 = 200;

            VerifyThat.AreEqual(ContactsPage.TotalContactsCountByLabel, expectedResult4, $"Alphabet side bar doesn't work. The sum of contacts being displayed is different from the expected. ContactsDisplayed={ContactsPage.TotalContactsCount}, Expected={expectedResult4}");

            AlphabetSideBar.SelectLetter(GreekAlphabet.Α);
            int expectedResult5 = 0;

            VerifyThat.AreEqual(ContactsPage.TotalContactsCountByLabel, expectedResult5, $"Alphabet side bar doesn't work. The sum of contacts being displayed is different from the expected. ContactsDisplayed={ContactsPage.TotalContactsCount}, Expected={expectedResult5}");

            AlphabetSideBar.SelectLetter(GreekAlphabet.Β);
            int expectedResult6 = 0;

            VerifyThat.AreEqual(ContactsPage.TotalContactsCountByLabel, expectedResult6, $"Alphabet side bar doesn't work. The sum of contacts being displayed is different from the expected. ContactsDisplayed={ContactsPage.TotalContactsCount}, Expected={expectedResult6}");
        }
Esempio n. 5
0
        public void Search_Using_Side_Alphabet_Bar()
        {
            LeftSideMenu.GoToCoworkers();

            AlphabetSideBar.SelectLetter(LatinAlphabet.R);
            int expectedResult1 = 1;

            VerifyThat.AreEqual(CoworkersPage.TotalCoworkersCountByLabel, expectedResult1, $"Alphabet side bar doesn't work. The sum of contacts being displayed is different from the expected. ContactsDisplayed={CoworkersPage.TotalCoworkersCountByLabel}, Expected={expectedResult1}");

            AlphabetSideBar.SelectLetter(LatinAlphabet.RestChars);
            int expectedResult2 = 10;

            VerifyThat.AreEqual(CoworkersPage.TotalCoworkersCountByLabel, expectedResult2, $"Alphabet side bar doesn't work. The sum of contacts being displayed is different from the expected. ContactsDisplayed={CoworkersPage.TotalCoworkersCountByLabel}, Expected={expectedResult2}");

            AlphabetSideBar.SelectLetter(GreekAlphabet.RestChars);
            int expectedResult4 = 1;

            VerifyThat.AreEqual(CoworkersPage.TotalCoworkersCountByLabel, expectedResult4, $"Alphabet side bar doesn't work. The sum of contacts being displayed is different from the expected. ContactsDisplayed={CoworkersPage.TotalCoworkersCountByLabel}, Expected={expectedResult4}");

            AlphabetSideBar.SelectLetter(GreekAlphabet.Κ);
            int expectedResult5 = 2;

            VerifyThat.AreEqual(CoworkersPage.TotalCoworkersCountByLabel, expectedResult5, $"Alphabet side bar doesn't work. The sum of contacts being displayed is different from the expected. ContactsDisplayed={CoworkersPage.TotalCoworkersCountByLabel}, Expected={expectedResult5}");

            AlphabetSideBar.SelectLetter(GreekAlphabet.Φ);
            int expectedResult6 = 1;

            VerifyThat.AreEqual(CoworkersPage.TotalCoworkersCountByLabel, expectedResult6, $"Alphabet side bar doesn't work. The sum of contacts being displayed is different from the expected. ContactsDisplayed={CoworkersPage.TotalCoworkersCountByLabel}, Expected={expectedResult6}");
        }
Esempio n. 6
0
        public void Search_Using_Side_Alphabet_Bar()
        {
            // Alphabet choice '#' was removed for Latin Alphabet

            //            AlphabetSideBar.SelectLetter(LatinAlphabet.RestChars);
            //            int expectedResult1 = 168;
            //            VerifyThat.AreEqual(ContactsPage.TotalContactsCountByLabel, expectedResult1, $"Alphabet side bar doesn't work using character '#' for latin alphabet. The sum of contacts being displayed is different from the expected. ContactsDisplayed={ContactsPage.TotalContactsCount}, Expected={expectedResult1}");

            AlphabetSideBar.SelectLetter(LatinAlphabet.Z);
            int expectedResult2 = 0;

            VerifyThat.AreEqual(ContactsPage.TotalContactsCountByLabel, expectedResult2, $"Alphabet side bar doesn't work using character 'Z' of latin alphabet. The sum of contacts being displayed is different from the expected. ContactsDisplayed={ContactsPage.TotalContactsCount}, Expected={expectedResult2}");

            AlphabetSideBar.SelectLetter(LatinAlphabet.P);
            int expectedResult3 = 2;

            VerifyThat.AreEqual(ContactsPage.TotalContactsCountByLabel, expectedResult3, $"Alphabet side bar doesn't work using character 'P' of latin alphabet. The sum of contacts being displayed is different from the expected. ContactsDisplayed={ContactsPage.TotalContactsCount}, Expected={expectedResult3}");

            // Alphabet choice '#' was removed for Greek Alphabet

            //            AlphabetSideBar.SelectLetter(GreekAlphabet.RestChars);
            //            int expectedResult4 = 35;
            //            VerifyThat.AreEqual(ContactsPage.TotalContactsCountByLabel, expectedResult4, $"Alphabet side bar doesn't work using character '#' for greek alphabet. The sum of contacts being displayed is different from the expected. ContactsDisplayed={ContactsPage.TotalContactsCount}, Expected={expectedResult4}");

            AlphabetSideBar.SelectLetter(GreekAlphabet.Α);
            int expectedResult5 = 4;

            VerifyThat.AreEqual(ContactsPage.TotalContactsCountByLabel, expectedResult5, $"Alphabet side bar doesn't work using character 'A' for greek alphabet. The sum of contacts being displayed is different from the expected. ContactsDisplayed={ContactsPage.TotalContactsCount}, Expected={expectedResult5}");

            AlphabetSideBar.SelectLetter(GreekAlphabet.Β);
            int expectedResult6 = 2;

            VerifyThat.AreEqual(ContactsPage.TotalContactsCountByLabel, expectedResult6, $"Alphabet side bar doesn't work using character 'B' for greek alphabet. The sum of contacts being displayed is different from the expected. ContactsDisplayed={ContactsPage.TotalContactsCount}, Expected={expectedResult6}");
        }
Esempio n. 7
0
 public static void CleanUp()
 {
     FirstOrganization.CleanUp();
     SecondOrganization.CleanUp();
     ThirdOrganization.CleanUp();
     LeftSideMenu.GoToContacts();
     VerifyThat.AreEqual(InitialOrganizationCount, OrganizationsPage.TotalOrganizationsCountByLabel,
                         $"Total organizations count is not the same as in the test initiation (Expected={InitialOrganizationCount}, Actual={OrganizationsPage.TotalOrganizationsCountByLabel}). Some organizations may have not been cleaned up at the end of test.");
 }
Esempio n. 8
0
        public void Filter_Using_Filter_By()
        {
            ContactsPage.FilterBy().SelectingAllowEmail().Filter();
            var expectedResult1 = 85;

            VerifyThat.AreEqual(ContactsPage.TotalContactsCountByLabel, expectedResult1, $"The sum of contacts being displayed, with Allow Emails = True, is different from the expected. ContactsDisplayed={ContactsPage.TotalContactsCount}, Expected={expectedResult1}");
            ContactsPage.ResetFilters();

            ContactsPage.FilterBy().SelectingAllowSMS().Filter();
            var expectedResult2 = 75;

            VerifyThat.AreEqual(ContactsPage.TotalContactsCountByLabel, expectedResult2, $"The sum of contacts being displayed, with Allow SMS = True, is different from the expected. ContactsDisplayed={ContactsPage.TotalContactsCount}, Expected={expectedResult2}");
            ContactsPage.ResetFilters();

            ContactsPage.FilterBy().SelectingAllowPhones().Filter();
            var expectedResult3 = 49;

            VerifyThat.AreEqual(ContactsPage.TotalContactsCountByLabel, expectedResult3, $"The sum of contacts being displayed, with Allow Phones = True, is different from the expected. ContactsDisplayed={ContactsPage.TotalContactsCount}, Expected={expectedResult3}");
            ContactsPage.ResetFilters();

            ContactsPage.FilterBy().SelectingOrphans().Filter();
            var expectedResult4 = 17;

            VerifyThat.AreEqual(ContactsPage.TotalContactsCountByLabel, expectedResult4, $"The sum of orphan contacts being displayed is different from the expected. ContactsDisplayed={ContactsPage.TotalContactsCount}, Expected={expectedResult4}");
            ContactsPage.ResetFilters();

            ContactsPage.FilterBy().SelectingDepartment(Department.Logistics).Filter();
            var expectedResult5 = 13;

            VerifyThat.AreEqual(ContactsPage.TotalContactsCountByLabel, expectedResult5, $"The sum of contacts being displayed and belong to Logistics department, is different from the expected. ContactsDisplayed={ContactsPage.TotalContactsCount}, Expected={expectedResult5}");
            ContactsPage.ResetFilters();

            ContactsPage.FilterBy().SelectingDepartment(Department.Consulting).Filter();
            var expectedResult6 = 57;

            VerifyThat.AreEqual(ContactsPage.TotalContactsCountByLabel, expectedResult6, $"The sum of contacts being displayed and belong to Consulting department, is different from the expected. ContactsDisplayed={ContactsPage.TotalContactsCount}, Expected={expectedResult6}");
            ContactsPage.ResetFilters();

            ContactsPage.FilterBy().SelectingAllowEmail().SelectingDepartment(Department.RnD).Filter();
            var expectedResult7 = 7;

            VerifyThat.AreEqual(ContactsPage.TotalContactsCountByLabel, expectedResult7, $"The sum of contacts being displayed, with Allow Email = True and belong to RnD department, is different from the expected. ContactsDisplayed={ContactsPage.TotalContactsCount}, Expected={expectedResult7}");
            ContactsPage.ResetFilters();

            ContactsPage.FilterBy()
            .SelectingAllowSMS()
            .SelectingAllowEmail()
            .SelectingDepartment(Department.Sales)
            .SelectingDepartment(Department.Administration)

            .Filter();
            var expectedResult8 = 6;

            VerifyThat.AreEqual(ContactsPage.TotalContactsCountByLabel, expectedResult8, $"The sum of contacts being displayed, with Allow SMS and Emails and belong either to the Sales or Administration departments, is different from the expected. ContactsDisplayed={ContactsPage.TotalContactsCount}, Expected={expectedResult8}");
        }
Esempio n. 9
0
        public void Assert_Contact_Comment_Field_Character_Limit_Indicator_Works_Correctly()
        {
            NewContactPage.GoTo();
            NewContactPage.SetComments(" " + DummyData.SimpleText);
            VerifyThat.AreEqual(500 - NewContactPage.CommentsTextLength, NewContactPage.CommentsLimitIndicator,
                                $"Comments text length is {500 - NewContactPage.CommentsTextLength} the value indicator is displaying is {NewContactPage.CommentsLimitIndicator}");

            NewContactPage.SetComments(DummyData.SimpleText);
            VerifyThat.AreEqual(500 - NewContactPage.CommentsTextLength, NewContactPage.CommentsLimitIndicator,
                                $"Comments text length is {500 - NewContactPage.CommentsTextLength} the value indicator is displaying is {NewContactPage.CommentsLimitIndicator}");
        }
        public void Import_Contacts_With_Invalid_Birthdate_Values()
        {
            ContactCreator.ImportTemplateContactWithInvalidBirthdate();
            AssertThat.IsTrue(ContactCreator.IsContactFileImportedSuccessfully, "Contact were not imported but they should.");
            ContactsPage.FindContact().WithFirstName(ContactCreator.FirstContact.FirstName).AndLastName(ContactCreator.FirstContact.LastName).Open();
            VerifyThat.AreEqual(ContactViewPage.Birthdate, "", $"Contact birthdate should be empty because imported contact's birthdate value is {ContactCreator.FirstContact.Birthdate} which is invalid.");

            ContactsPage.FindContact().WithFirstName(ContactCreator.SecondContact.FirstName).AndLastName(ContactCreator.SecondContact.LastName).Open();
            VerifyThat.AreEqual(ContactViewPage.Birthdate, "", $"Contact birthdate should be empty because imported contact's birthdate value is {ContactCreator.SecondContact.Birthdate} which is invalid.");

            ContactsPage.FindContact().WithFirstName(ContactCreator.ThirdContact.FirstName).AndLastName(ContactCreator.ThirdContact.LastName).Open();
            VerifyThat.AreEqual(ContactViewPage.Birthdate, "", $"Contact birthdate should be empty because imported contact's birthdate value is {ContactCreator.ThirdContact.Birthdate} which is invalid.");
        }
Esempio n. 11
0
        public void Filter_Using_Department_Filter()
        {
            CoworkersPage.FilterBy().SelectingDepartment(Department.RnD).Filter();
            var expectedResult1 = 4;

            VerifyThat.AreEqual(CoworkersPage.TotalCoworkersCount, expectedResult1,
                                $"The sum of contacts being displayed, with Allow Emails = True, is different from the expected. ContactsDisplayed={CoworkersPage.TotalCoworkersCount}, Expected={expectedResult1}");
            CoworkersPage.ResetFilters();

            CoworkersPage.FilterBy().SelectingDepartment(Department.Administration).SelectingDepartment(Department.Consulting).Filter();
            var expectedResult2 = 5;

            VerifyThat.AreEqual(CoworkersPage.TotalCoworkersCount, expectedResult2,
                                $"The sum of contacts being displayed, with Allow Emails = True, is different from the expected. ContactsDisplayed={CoworkersPage.TotalCoworkersCount}, Expected={expectedResult2}");
            CoworkersPage.ResetFilters();
        }
Esempio n. 12
0
        public void Can_Use_Contactlist_Searchbox()
        {
            ContactsPage.FindContact().ContainingKeyword("lavi").Find();
            int expectedResult1 = 1;

            VerifyThat.AreEqual(ContactsPage.TotalContactsCount, expectedResult1, $"Search using organization field, with keyword = 'lavi', doesn't work. The sum of contacts being displayed is different from the expected. ContactsDisplayed={ContactsPage.TotalContactsCount}, Expected={expectedResult1}");

            ContactsPage.FindContact().ContainingKeyword("παπα").Find();
            int expectedResult2 = 9;

            VerifyThat.AreEqual(ContactsPage.TotalContactsCount, expectedResult2, $"Search using last name field, with keyword = 'παπα', doesn't work. The sum of contacts being displayed is different from the expected. ContactsDisplayed={ContactsPage.TotalContactsCount}, Expected={expectedResult2}");

            ContactsPage.FindContact().ContainingKeyword("πούλου").Find();
            int expectedResult3 = 6;

            VerifyThat.AreEqual(ContactsPage.TotalContactsCount, expectedResult3, $"Search using last name field, with keyword = 'πούλου', doesn't work. The sum of contacts being displayed is different from the expected. ContactsDisplayed={ContactsPage.TotalContactsCount}, Expected={expectedResult3}");
        }
Esempio n. 13
0
        public void Search_Using_Searchbox()
        {
            ContactsPage.FindContact().ContainingKeyword("lavi").Find();
            int expectedResult1 = 1;

            VerifyThat.AreEqual(ContactsPage.TotalContactsCountByLabel, expectedResult1, $"Search using organization field, with keyword = 'lavi', doesn't work. The sum of contacts being displayed is different from the expected. ContactsDisplayed={ContactsPage.TotalContactsCount}, Expected={expectedResult1}");

            ContactsPage.FindContact().ContainingKeyword("παπα").Find();
            int expectedResult2 = 9;

            VerifyThat.AreEqual(ContactsPage.TotalContactsCountByLabel, expectedResult2, $"Search using surname field, with keyword = 'παπα', doesn't work. The sum of contacts being displayed is different from the expected. ContactsDisplayed={ContactsPage.TotalContactsCount}, Expected={expectedResult2}");

            ContactsPage.FindContact().ContainingKeyword("21066").Find();
            int expectedResult3 = 1;

            VerifyThat.AreEqual(ContactsPage.TotalContactsCountByLabel, expectedResult3, $"Search using phone field, with keyword = '21066', doesn't work. The sum of contacts being displayed is different from the expected. ContactsDisplayed={ContactsPage.TotalContactsCount}, Expected={expectedResult3}");

            ContactsPage.FindContact().ContainingKeyword("αργυρουπ").Find();
            int expectedResult4 = 18;

            VerifyThat.AreEqual(ContactsPage.TotalContactsCountByLabel, expectedResult4, $"Search using city field, with keyword = 'αργυρουπ', doesn't work. The sum of contacts being displayed is different from the expected. ContactsDisplayed={ContactsPage.TotalContactsCount}, Expected={expectedResult4}");

            ContactsPage.FindContact().ContainingKeyword("βουλιαγμ").Find();
            int expectedResult5 = 13;

            VerifyThat.AreEqual(ContactsPage.TotalContactsCountByLabel, expectedResult5, $"Search using street field, with keyword = 'βουλιαγμ', doesn't work. The sum of contacts being displayed is different from the expected. ContactsDisplayed={ContactsPage.TotalContactsCount}, Expected={expectedResult5}");

            ContactsPage.FindContact().ContainingKeyword("roma").Find();
            int expectedResult6 = 21;

            VerifyThat.AreEqual(ContactsPage.TotalContactsCountByLabel, expectedResult6, $"Search using country field, with keyword = 'roma', doesn't work. The sum of contacts being displayed is different from the expected. ContactsDisplayed={ContactsPage.TotalContactsCount}, Expected={expectedResult6}");

            ContactsPage.FindContact().ContainingKeyword("director").Find();
            int expectedResult7 = 7;

            VerifyThat.AreEqual(ContactsPage.TotalContactsCountByLabel, expectedResult7, $"Search using job title field, with keyword = 'director', doesn't work. The sum of contacts being displayed is different from the expected. ContactsDisplayed={ContactsPage.TotalContactsCount}, Expected={expectedResult7}");

            ContactsPage.FindContact().ContainingKeyword("kosmocar.gr").Find();
            int expectedResult8 = 17;

            VerifyThat.AreEqual(ContactsPage.TotalContactsCount, expectedResult8, $"Search using website field, with keyword = 'kosmocar.gr', doesn't work. The sum of contacts being displayed is different from the expected. ContactsDisplayed={ContactsPage.TotalContactsCount}, Expected={expectedResult8}");
        }
Esempio n. 14
0
        public void General_Search_Returns_Correct_Results_From_All_Entities()
        {
            UpperToolBar.UseGeneralSearch().WithKeyword("Kor").Search();
            var expectedResult1 = 5;

            VerifyThat.AreEqual(UpperToolBar.GeneralSearchContactsDisplayed, expectedResult1, $"Number of contacts returned from search of is incorrect for keyword 'kor'. Expected={expectedResult1}, Actual={UpperToolBar.GeneralSearchContactsDisplayed}");

            UpperToolBar.UseGeneralSearch().WithKeyword("2310").Search();
            var expectedResult2 = 2;

            VerifyThat.AreEqual(UpperToolBar.GeneralSearchContactsDisplayed, expectedResult2, $"Number of contacts returned from search is incorrect for keyword '2310'. Expected={expectedResult2}, Actual={UpperToolBar.GeneralSearchContactsDisplayed}");

            UpperToolBar.UseGeneralSearch().WithKeyword("leroymerlin").Search();
            var expectedResult3 = 2;

            VerifyThat.AreEqual(UpperToolBar.GeneralSearchContactsDisplayed, expectedResult3, $"Number of contacts returned from search is incorrect for keyword 'leroymerlin'. Expected={expectedResult3}, Actual={UpperToolBar.GeneralSearchContactsDisplayed}");

            UpperToolBar.UseGeneralSearch().WithKeyword("Zurich").Search();
            var expectedResult4 = 3;

            VerifyThat.AreEqual(UpperToolBar.GeneralSearchContactsDisplayed, expectedResult4, $"Number of contacts returned from search is incorrect for keyword 'Zurich'. Expected={expectedResult4}, Actual={UpperToolBar.GeneralSearchContactsDisplayed}");

            UpperToolBar.UseGeneralSearch().WithKeyword("Project Manager").Search();
            var expectedResult5 = 2;

            VerifyThat.AreEqual(UpperToolBar.GeneralSearchContactsDisplayed, expectedResult5, $"Number of contacts returned from search is incorrect for keyword 'Project Manager'. Expected={expectedResult5}, Actual={UpperToolBar.GeneralSearchContactsDisplayed}");

            UpperToolBar.UseGeneralSearch().WithKeyword("www.mas").Search();
            var expectedResult6 = 2;

            VerifyThat.AreEqual(UpperToolBar.GeneralSearchOrganizationsDisplayed, expectedResult6, $"Number of contacts returned from search is incorrect for keyword 'www.mas'. Expected={expectedResult6}, Actual={UpperToolBar.GeneralSearchOrganizationsDisplayed}");

            UpperToolBar.UseGeneralSearch().WithKeyword("Παπανδρέου").Search();
            var expectedResult7 = 2;

            VerifyThat.AreEqual(UpperToolBar.GeneralSearchOrganizationsDisplayed, expectedResult7, $"Number of contacts returned from search is incorrect for keyword 'Παπανδρέου'. Expected={expectedResult7}, Actual={UpperToolBar.GeneralSearchOrganizationsDisplayed}");
        }