daily pastebin goal
56%
SHARE
TWEET

Untitled

a guest Jul 13th, 2018 68 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. using Microsoft.VisualStudio.TestTools.UnitTesting;
  2. using OpenQA.Selenium;
  3. using OpenQA.Selenium.PhantomJS;
  4. [TestClass]
  5.   public class UnitTest1
  6.   {
  7.     const string PhantomDirectory = @"......packagesPhantomJS.2.1.1toolsphantomjs";
  8.  
  9. [TestMethod]
  10.     public void GetSproutsWeeklyAdDetails()
  11.     {
  12.       using (IWebDriver phantomDriver = new PhantomJSDriver(PhantomDirectory))
  13.       {
  14.         phantomDriver.Navigate().GoToUrl("https://shop.sprouts.com/shop/flyer");
  15.         var elements = phantomDriver.FindElements(By.ClassName("cell-title-text"));
  16.       }
  17.     }
  18. }
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
 
Top