Exemplo n.º 1
0
        public void Verify_Receiver_Field()
        {
            EmailPage emailPage = new EmailPage(driver);

            emailPage.IncomingMailsTab().Click();
            emailPage.FirstMail().Click();
            Assert.AreEqual("*****@*****.**", emailPage.Receiver().Text);
        }
Exemplo n.º 2
0
        public void Verify_Description_Field()
        {
            EmailPage emailPage = new EmailPage(driver);

            emailPage.IncomingMailsTab().Click();
            emailPage.FirstMail().Click();
            Assert.IsTrue(emailPage.Description().Text.Contains("Description Test"));
        }
Exemplo n.º 3
0
        public void Verify_Subject_Field()
        {
            EmailPage emailPage = new EmailPage(driver);

            emailPage.IncomingMailsTab().Click();
            emailPage.FirstMail().Click();
            Assert.AreEqual("Letter for test", emailPage.Subject().Text);
        }
Exemplo n.º 4
0
        public void Create_New_Mail()
        {
            EmailPage emailPage = new EmailPage(driver);

            emailPage.CreateNewLetter();
            emailPage.IncomingMailsTab().Click();
            Assert.AreEqual("Letter for test", emailPage.SubjectOfIncomingMail().Text);
        }
Exemplo n.º 5
0
        public void Verify_Fields_Of_Sent_Letter()
        {
            EmailPage emailPage = new EmailPage(driver);

            emailPage.CreateNewLetter();
            emailPage.IncomingMailsTab().Click();
            emailPage.FirstMail().Click();

            Assert.AreEqual("Letter for test", emailPage.Subject().Text);
            Assert.IsTrue(emailPage.Description().Text.Contains("Description Test"));
            Assert.AreEqual("*****@*****.**", emailPage.Receiver().Text);
        }
Exemplo n.º 6
0
        public void DownloadFile()
        {
            string FilePath = @"C:\Users\Lenovo Y500\Desktop\TestFiles\";

            EmailPage emailPage = new EmailPage(driver);

            emailPage.IncomingMailsTab().Click();
            emailPage.FirstMail().Click();

            driver.FindElement(By.LinkText("UploadTEST.txt")).Click();
            Thread.Sleep(2000);
        }
Exemplo n.º 7
0
        public void UploadFile()
        {
            string File     = "UploadTEST.txt";
            string FilePath = @"C:\Users\Lenovo Y500\Desktop\" + File;

            EmailPage emailPage = new EmailPage(driver);

            emailPage.CreateLetterBtn().Click();
            emailPage.ReceiverField().SendKeys("*****@*****.**");
            emailPage.SubjectField().SendKeys("Letter for test");
            emailPage.DescriptionField().SendKeys("Description Test");
            driver.FindElement(By.XPath("//*[@id='att']/div[2]/span[1]/i")).Click();
            Thread.Sleep(2000);
            driver.FindElement(By.XPath("//input[@type='file']")).SendKeys(FilePath);
            Thread.Sleep(2000);
            emailPage.SentMailButton().Click();
            emailPage.IncomingMailsTab().Click();
            emailPage.FirstMail().Click();
        }