コード例 #1
0
        public static void TestJEMPage()
        {
            Driver.GoToSite(URL.JEMPageUrl);
            string actualHeaderText   = JEMPage.GetJEMHeroHeader();
            string expectedHeaderText = "Less talk, more eat.";

            Assert.AreEqual(expectedHeaderText, actualHeaderText);
            Console.WriteLine($"Actual Header Text : {actualHeaderText} \n Expected Header Text : {expectedHeaderText}");

            string actualSubHeaderText   = JEMPage.GetJEMHeroSubHeader();
            string expectedSubHeaderText = "Your favourite local restaurants delivered";

            Assert.IsTrue(actualSubHeaderText.ToString().Equals(expectedSubHeaderText));
            Console.WriteLine($"Actual SubHeader Text : {actualSubHeaderText}  Expected SubHeader Text : {expectedSubHeaderText}");
        }
コード例 #2
0
 public static void TestRestaurantCountUsingTestDataList()
 {
     logger.Info("Test Restaurant Count");
     try
     {
         foreach (string suburb in TestData.GetTestData())
         {
             string searchSuburb = suburb.TrimEnd().TrimStart();
             Driver.GoToSite(URL.JEMPageUrl);
             JEMPage.EnterSuburbSearchText(searchSuburb);
             string actualResturantCount = JEMSerpPage.GetJEMRestaurantCount();
             logger.Info($"{suburb} Restaurant Count : {actualResturantCount} ");
         }
     }
     catch (Exception e)
     {
     }
 }
コード例 #3
0
 public static void TestRestaurantCountUsingGoogleSreadSheest()
 {
     logger.Info("Test Restaurant Count");
     testData = GoogleAuth.GetData(sheetID);
     try
     {
         foreach (var data in testData)
         {
             string searchSuburb = data[0].ToString();
             Driver.GoToSite(URL.JEMPageUrl);
             JEMPage.EnterSuburbSearchText(searchSuburb);
             string actualResturantCount = JEMSerpPage.GetJEMRestaurantCount();
             logger.Info($"{searchSuburb} Restaurant Count : {actualResturantCount} ");
         }
     }
     catch (Exception e)
     {
     }
 }