public BookingPage StepVerifyEmail(string email)
 {
     Assert.AreEqual(EnterEmail.GetAttribute("value"), email);
     Console.WriteLine("Email address is correct!");
     Thread.Sleep(3000);
     return(this);
 }
Ejemplo n.º 2
0
 public void ExistingUser()
 {
     SignInButton.Click();
     Thread.Sleep(1000);
     EnterEmail.SendKeys("*****@*****.**");
     EnterPassword.SendKeys("123qwe");
     Login.Submit();
 }
        public void UserEntersInitialInfo(string firstName, string lastName, string email)
        {
            WebDriverWait wait = new WebDriverWait(driver, TimeSpan.FromSeconds(30));

            wait.Until(ExpectedConditions.ElementToBeClickable(_txtFirstName));
            FirstName.SendKeys(firstName);
            Thread.Sleep(2000);
            wait.Until(ExpectedConditions.ElementToBeClickable(_txtLastName));
            LastName.SendKeys(lastName);
            Thread.Sleep(2000);
            wait.Until(ExpectedConditions.ElementToBeClickable(_txtEmail));
            EnterEmail.SendKeys(email);
        }
Ejemplo n.º 4
0
 public void Login_Checkout()
 {
     EnterEmail.SendKeys("*****@*****.**");
     EnterPassword.SendKeys("123qwe");
     Login.Submit();
 }
 public BookingPage StepEnterEmail(string email)
 {
     EnterEmail.SendKeys(email);
     Thread.Sleep(2000);
     return(this);
 }
Ejemplo n.º 6
0
 public void Login(String username, String password)
 {
     EnterEmail.SendKeys(username);
     EnterPassword.SendKeys(password);
     LoginBtn.Click();
 }
Ejemplo n.º 7
0
        private void RegisterBtn_Click_1(object sender, RoutedEventArgs e)
        {
            Rooms.LoginRegister.Register register = new LoginRegister.Register();
            string username        = EnterUsername.Text;
            string password        = EnterPassword.Password.ToString();
            string confirmpassword = ConfirmPassword.Password.ToString();
            string firstname       = EnterName.Text;
            string lastname        = EnterSurname.Text;

            bool checkInstructor;

            if (InstructorRadioBtn.IsChecked == true)
            {
                checkInstructor = true;
            }
            else
            {
                checkInstructor = false;
            }


            string email = EnterEmail.Text;

            utilizator.username  = username;
            utilizator.password  = password;
            utilizator.firstname = firstname;
            utilizator.lastname  = lastname;
            utilizator.email     = email;
            utilizator.Role      = InstructorRadioBtn.IsEnabled ? Rol_Utilizator.Membru : Rol_Utilizator.Administrator;

            try
            {
                utilizator newUser = register.Valideaza_Inregistrare(username, password, firstname, lastname, confirmpassword, checkInstructor, email);
                MessageBox.Show("Welcome to Rooms 404. Enjoy!");

                AdminFormularService adminFormularService = new AdminFormularService();

                student = adminFormularService.GetStudent(utilizator.id);

                if (newUser.Role.ToString().Equals("Membru"))
                {
                    StudentModule mainWindow = new StudentModule(utilizator, student);
                    mainWindow.Show();
                    this.Close();
                }
                else if (newUser.Role.ToString().Equals("Administrator"))
                {
                    AdminModule adminModule = new AdminModule(utilizator);
                    adminModule.Show();
                    this.Close();
                }
            }
            catch (Exception ex)
            {
                EnterUsername.Clear();
                EnterPassword.Clear();
                EnterName.Clear();
                EnterSurname.Clear();
                EnterEmail.Clear();

                MessageBox.Show(ex.Message);
            }
        }
Ejemplo n.º 8
0
 public void EnterEmailAddress(string myemail)
 {
     EnterEmail.SendKeys(myemail);
 }
 public AirportTaxisPage StepEnterEmail(string email)
 {
     EnterEmail.SendKeys(email);
     Thread.Sleep(2000);
     return(this);
 }