public MainPage(IWebDriver driver) : base(driver) { if (!MAIN_PAGE_TITLE.Equals(GetPageTitle())) { throw new Exception("This is not main page!"); } PageFactory.InitElements(_driver, this); }
public LoginSignupPage(IWebDriver driver) : base(driver) { if (!MAIN_PAGE_TITLE.Equals(GetPageTitle())) { throw new Exception("This is not a '" + MAIN_PAGE_TITLE + "' main page:" + GetPageTitle()); } PageFactory.InitElements(_driver, this); }