示例#1
0
 public void BeforeScenario()
 {
     //TODO: implement logic that has to run before executing each scenario
     BrowserDriver.InitBrowser("Chrome");
     BrowserDriver.Driver.Manage().Cookies.DeleteAllCookies();
     BrowserDriver.LoadApplication(ConfigurationManager.AppSettings["URL"]);
     scenario = featureName.CreateNode <Scenario>(ScenarioContext.Current.ScenarioInfo.Title);
 }
        public void TestPageObjects()
        {
            BrowserDriver.InitBrowser("Chrome");
            BrowserDriver.LoadApplication(ConfigurationManager.AppSettings["URL"]);

            Page.Home.ClickOnMyAccount();
            Page.Login.EnterLoginDetails("LogInTestWithPageObjects");
            Page.Login.ClickSignIn();

            BrowserDriver.CloseAllDrivers();
        }