Exemplo n.º 1
0
        public void CAP_TC6_Create_ArticlePageDisplayed()
        {
            var createArticlePage = new CreateArticlePage(driver);

            createArticlePage.NavigateTo();

            createArticlePage.AssertCreateArticlePageIsDisplayed("Create Article");
        }
Exemplo n.º 2
0
        public void CAP_TC5_Create_ArticleWithoutTitle_Content()
        {
            var createArticlePage = new CreateArticlePage(driver);

            createArticlePage.NavigateTo();
            createArticlePage.CreateArticleButton.Click();

            createArticlePage.AssertCreateArticleWithoutTitle_andContent("The Title field is required.", "The Content field is required.");
        }
Exemplo n.º 3
0
        public void CAP_TC2_Cancel_Empty_Article()
        {
            var createArticlePage = new CreateArticlePage(driver);

            createArticlePage.NavigateTo();
            createArticlePage.CancelArticleButton.Click();

            createArticlePage.AssertCreateArticleWithValidData("Test Automation is the key");
        }
Exemplo n.º 4
0
        public void CAP_TC4_Create_ArticleWithoutTitle()
        {
            var createArticlePage = new CreateArticlePage(driver);

            createArticlePage.NavigateTo();
            createArticlePage.Content.SendKeys("tralala");
            createArticlePage.CreateArticleButton.Click();

            createArticlePage.AssertCreateArticleWithoutTitle("The Title field is required.");
        }
Exemplo n.º 5
0
        public void CAP_TC3_Create_ArticleWithoutContent()
        {
            var createArticlePage = new CreateArticlePage(driver);

            createArticlePage.NavigateTo();
            createArticlePage.Title.SendKeys("Tralala");
            createArticlePage.CreateArticleButton.Click();

            createArticlePage.AssertCreateArticleWithoutContent("The Content field is required.");
        }
Exemplo n.º 6
0
        public void CAP_TC1_CreateArticleWithValidData()
        {
            var createArticlePage = new CreateArticlePage(driver);
            var articleContent    = new CreateArticleContent("Test Automation is the key", "Traditional quality assurance has become a bottleneck in the development process and the advancement of test automation. Innovative development teams ...");

            createArticlePage.NavigateTo();
            createArticlePage.FillCreateArticleForm(articleContent);

            createArticlePage.AssertCreateArticleWithValidData("Test Automation is the key");
        }
Exemplo n.º 7
0
        public void CAP_TC6_Create_ArticlePageDisplayed()
        {
            var loginPage = new LoginPage(driver);
            var user      = new LoginUser("*****@*****.**", "1234");

            loginPage.NavigateTo();
            loginPage.FillRegistrationForm(user);
            var createArticlePage = new CreateArticlePage(driver);

            createArticlePage.NavigateTo();
            createArticlePage.AssertCreateArticlePageIsDisplayed("Create Article");
        }
Exemplo n.º 8
0
        public void CAP_TC5_Create_ArticleWithoutTitle_Content()
        {
            var loginPage = new LoginPage(driver);
            var user      = new LoginUser("*****@*****.**", "1234");

            loginPage.NavigateTo();
            loginPage.FillRegistrationForm(user);
            var createArticlePage = new CreateArticlePage(driver);

            createArticlePage.NavigateTo();
            createArticlePage.Title.Clear();
            createArticlePage.Content.Clear();
            createArticlePage.CreateArticleButton.Click();
            createArticlePage.AssertCreateArticleWithoutTitle_andContent("The Title field is required.", "The Content field is required.");
        }
        public void CAP_TC3_Create_ArticleWithoutContent()
        {
            var loginPage = new LoginPage(driver);
            var user      = new LoginUser("*****@*****.**", "1234");

            loginPage.NavigateTo();
            loginPage.FillLoginForm(user);
            var createArticlePage = new CreateArticlePage(driver);

            createArticlePage.NavigateTo();
            createArticlePage.Title.Clear();
            createArticlePage.Title.SendKeys("Tralala");
            createArticlePage.Content.Clear();
            createArticlePage.CreateArticleButton.Click();
            createArticlePage.AssertCreateArticleWithoutContent("The Content field is required.");
        }
Exemplo n.º 10
0
        public void CAP_TC2_Cancel_Empty_Article()
        {
            var loginPage = new LoginPage(driver);
            var user      = new LoginUser("*****@*****.**", "1234");

            loginPage.NavigateTo();
            loginPage.FillRegistrationForm(user);

            var createArticlePage = new CreateArticlePage(driver);

            createArticlePage.NavigateTo();
            createArticlePage.Title.Clear();
            createArticlePage.Content.Clear();
            createArticlePage.CancelArticleButton.Click();
            createArticlePage.AssertCreateArticleWithValidData("Test Automation is the key");
        }
Exemplo n.º 11
0
        public void CAP_TC7_Create_ArticleContentResize()
        {
            var createArticlePage = new CreateArticlePage(driver);

            createArticlePage.NavigateTo();

            Actions builder = new Actions(this.driver);
            var     action  = builder.MoveToElement(createArticlePage.Content)
                              .MoveByOffset((createArticlePage.Content.Size.Width / 2) - 2, (createArticlePage.Content.Size.Height / 2) - 2)
                              .ClickAndHold()
                              .MoveByOffset(300, 300)
                              .Release();

            action.Perform();
            createArticlePage.AssertCreateArticlePageIsDisplayed("Create Article");
            createArticlePage.AssertCreateArticleComtentresized(300);
        }