Пример #1
0
        public void TestAddingIntoSpam()
        {
            autorisation.SetLogin(user1.Login);
            autorisation.SetPassword(user1.Password);
            sendingMess.CreateMessage(user2.Login, Data.FirstMessage + "from " + handler.GetCity());
            sendingMess.SendMessage();

            exit.LogOut();
            exit.ChangeAccount();
            exit.AddAccount();
            autorisation.SetLogin(user2.Login);
            autorisation.SetPassword(user2.Password);
            spamMessage.PutIntoSpam();
            exit.LogOut();
            exit.AddAccount();
            autorisation.SetLogin(user1.Login);
            autorisation.SetPassword(user1.Password);
            sendingMess.CreateMessage(user2.Login, Data.SecondMessage);
            sendingMess.SendMessage();
            exit.LogOut();
            exit.AddAccount();
            autorisation.SetLogin(user2.Login);
            autorisation.SetPassword(user2.Password);
            spamMessage.OpenSpam();
            sendingMess.OpenMessage();
            string message = sendingMess.GetMessageText();

            Assert.AreEqual(Data.SecondMessage, message);
            Assert.IsTrue(true);
        }
Пример #2
0
        public void Cleanup()
        {
            exit.LogOut();
            exit.AddAccount();

            autorisation.SetLogin(user2.Login);
            autorisation.SetPassword(user2.Password);
            // sett.OpenSettings();
            settings.OpenLinkSettings();
            settings.ChooseForwardPage();

            settings.ClearSettings();
            Thread.Sleep(1000);
            WebDriver.CloseWebDriver();
        }