Course Solutions Uncategorized (Solved) : Mention Program Chegg Login Using Java Selenium Complete Working Program Error Add Functio Q29488228 . . . .

(Solved) : Mention Program Chegg Login Using Java Selenium Complete Working Program Error Add Functio Q29488228 . . . .

 

The mention program is Chegg login by using Java andSelenium. This is complete working program no error. Onlyadd some functionality:
i) Add the functionality of logout after successful login theaccount
ii)After logout exit the firefox browser that openthe Chegg site.

Note: I mentioned complete source codeand image of my Eclipse IDE.

Program:

package automationframework;

import org.openqa.selenium.WebDriver;
import org.openqa.selenium.chrome.ChromeDriver;
import org.openqa.selenium.firefox.FirefoxDriver;
import org.testng.Assert;

import java.util.List;
import java.util.concurrent.TimeUnit;

import org.openqa.selenium.By;
import org.openqa.selenium.WebDriver;
import org.openqa.selenium.WebElement;

public class OpenChegg
{

   public static String driverPath = “f:/”;
   public static WebDriver driver;
   
       public static void main(String[]args) throws InterruptedException {
          System.out.println(“launching chrome browser”);
        
          //System.setProperty(“webdriver.chrome.driver”,driverPath+”chromedriver.exe”);
        
          //driver = new ChromeDriver();
          System.setProperty(“webdriver.gecko.driver”,”c:/geckodriver.exe”);
          WebDriver driver = new FirefoxDriver();
          driver.navigate().to(“https://www.chegg.com/auth?action=login&reset_password=0”);
          driver.findElement(By.xpath(“//*[@id[contains(.,’emailForSignIn’)]]”)).sendKeys(“abcdef@vfx.com”);
          driver.findElement(By.xpath(“//*[@id[contains(.,’passwordForSignIn’)]]”)).sendKeys(“defgh”);
          driver.findElement(By.xpath(“//button[text()=’Signin’]”)).click();
          //WebElement e = driver.findElement(By.xpath(“//*[text()=’sarikajain’]”));
          driver.manage().timeouts().implicitlyWait(10,TimeUnit.SECONDS);
          System.out.println(“wait to respond………”);
       Thread.sleep(10);
        
        
          List<WebElement> list =driver.findElements(By.xpath(“//*[contains(text(),'” + “Email andpassword do not match.”

OR

PayPal Gateway not configured

OR

PayPal Gateway not configured

Leave a Reply

Your email address will not be published. Required fields are marked *

Related Post

(Solved) : Matlab Assignment Numerical Approximation Many Differential Equations Means Solving Go Ex Q29805064 . . . .(Solved) : Matlab Assignment Numerical Approximation Many Differential Equations Means Solving Go Ex Q29805064 . . . .

<br/><img src="https://media.cheggcdn.com/media%2F28b%2F28bd2c4f-1fe0-4105-8d7c-4ac04d37dff1%2Fimage" alt="This MATLAB assignment will be about numerical approximation, which for many differential equations is the only means of solving them. We will go through some examples related to