Ejemplo n.º 1
0
        //  [AssemblyInitialize]
        public static void Initialize(Microsoft.VisualStudio.TestTools.UnitTesting.TestContext tc)
        {
            switch (ConfigurationManager.AppSettings.Get(AppConfigKeys.Browser))
            {
            case "Firefox":
                ObjectRepository.Driver = GetFirefoxDriver();
                NavigateHelper.WebSite(ConfigurationManager.AppSettings.Get(AppConfigKeys.WebSite));
                break;

            case "Chrome":
                ObjectRepository.Driver = GetChromeBrowseer();
                NavigateHelper.WebSite(ConfigurationManager.AppSettings.Get(AppConfigKeys.WebSite));
                break;

            case "IE":
                //   ObjectRepository.IEOptions = GetIEDriver();
                ObjectRepository.Driver = new InternetExplorerDriver(GetIEDriver());
                NavigateHelper.WebSite(ConfigurationManager.AppSettings.Get(AppConfigKeys.WebSite));
                break;
            }
        }
Ejemplo n.º 2
0
 public void GivenUserIsAtLoginPageWithTitle(string title)
 {
     NavigateHelper.WebSite(ConfigurationManager.AppSettings.Get(AppConfigKeys.WebSite));
     Assert.AreEqual(title, ObjectRepository.Driver.Title);
 }