public void CheckSquareCenterFieldIsClickable() { var playInPage = new PlayInPage(_webDriver); playInPage.GoToPlayInPage(); playInPage.ClickCenter(); Thread.Sleep(500); var actualResult = playInPage.GetCenter(); Assert.AreEqual("x", actualResult); }
public void CheckUpdateScoreForAppear() { var playInPage = new PlayInPage(_webDriver); playInPage.GoToPlayInPage(); playInPage.ClickPlayer2(); playInPage.ClickRight(); playInPage.ClickLeft(); playInPage.ClickTopRight(); playInPage.ClickBottomLeft(); playInPage.ClickCenter(); playInPage.ClickTopLeft(); Thread.Sleep(3000); var actualResult = playInPage.GetScoreAppear(); Assert.AreEqual("1", actualResult); }
public void EasyWin() { var playInPage = new PlayInPage(_webDriver); playInPage.GoToPlayInPage(); playInPage.ClickCenter(); Thread.Sleep(2000); if (playInPage.GetRight() == "o" || playInPage.GetTop() == "o" || playInPage.GetBottom() == "o" || playInPage.GetLeft() == "o") { playInPage.ClickBottomRight(); Thread.Sleep(1000); } else if (playInPage.GetBottomRight() == "o" || playInPage.GetTopRight() == "o" || playInPage.GetBottomLeft() == "o" || playInPage.GetTopLeft() == "o") { playInPage.ClickTopRight(); } playInPage.ClickBottomLeft(); Thread.Sleep(2000); if (playInPage.GetTopRight() != "o") { playInPage.ClickTopRight(); Thread.Sleep(2000); } else if (playInPage.GetBottom() != "o") { playInPage.ClickBottom(); Thread.Sleep(2000); } var actualResult = playInPage.GetScoreAppear(); Assert.AreEqual("1", actualResult); }