Пример #1
0
        public void EnterUserDetails()
        {
            string password = TestData.RandomPassword();

            if (Username.Displayed)
            {
                Username.Clear();
                Username.SendKeys(TestData.RandomUserName());
                Console.WriteLine(Username.GetAttribute("value"));
            }
            if (Password.Displayed)
            {
                Password.Clear();
                Password.SendKeys(password);
                Console.WriteLine(Password.GetAttribute("value"));
            }
            if (ConfirmPassword.Displayed)
            {
                ConfirmPassword.Clear();
                ConfirmPassword.SendKeys(password);
                Console.WriteLine(ConfirmPassword.GetAttribute("value"));
            }
            if (SubmitButton.Displayed)
            {
                SubmitButton.Click();
                Thread.Sleep(5000);
            }
        }