fork download
  1. package com.example.tests;
  2.  
  3. import java.util.regex.Pattern;
  4. import java.util.concurrent.TimeUnit;
  5. import org.junit.*;
  6. import static org.junit.Assert.*;
  7. import static org.hamcrest.CoreMatchers.*;
  8. import org.openqa.selenium.*;
  9. import org.openqa.selenium.firefox.FirefoxDriver;
  10. import org.openqa.selenium.support.ui.Select;
  11.  
  12. public class Poke {
  13. private WebDriver driver;
  14. private String baseUrl;
  15. private boolean acceptNextAlert = true;
  16. private StringBuffer verificationErrors = new StringBuffer();
  17.  
  18. public void main()
  19. {
  20. while (1)
  21. {
  22. river = new FirefoxDriver();
  23. baseUrl = "https://w...content-available-to-author-only...k.com/";
  24. driver.manage().timeouts().implicitlyWait(30, TimeUnit.SECONDS);
  25. driver.get(baseUrl + "/pokes?notif_t=poke");
  26. driver.findElement(By.linkText("Poke Back")).click();
  27. }
  28. }
  29. }
Compilation error #stdin compilation error #stdout 0s 0KB
stdin
Standard input is empty
compilation info
Main.java:12: error: class Poke is public, should be declared in a file named Poke.java
public class Poke {
       ^
Main.java:5: error: package org.junit does not exist
import org.junit.*;
^
Main.java:6: error: package org.junit does not exist
import static org.junit.Assert.*;
                       ^
Main.java:7: error: package org.hamcrest does not exist
import static org.hamcrest.CoreMatchers.*;
                          ^
Main.java:8: error: package org.openqa.selenium does not exist
import org.openqa.selenium.*;
^
Main.java:9: error: package org.openqa.selenium.firefox does not exist
import org.openqa.selenium.firefox.FirefoxDriver;
                                  ^
Main.java:10: error: package org.openqa.selenium.support.ui does not exist
import org.openqa.selenium.support.ui.Select;
                                     ^
Main.java:13: error: cannot find symbol
  private WebDriver driver;
          ^
  symbol:   class WebDriver
  location: class Poke
Main.java:20: error: incompatible types
    while (1)
           ^
  required: boolean
  found:    int
Main.java:22: error: cannot find symbol
        river = new FirefoxDriver();
        ^
  symbol:   variable river
  location: class Poke
Main.java:22: error: cannot find symbol
        river = new FirefoxDriver();
                    ^
  symbol:   class FirefoxDriver
  location: class Poke
Main.java:26: error: cannot find symbol
    	driver.findElement(By.linkText("Poke Back")).click();
    	                   ^
  symbol:   variable By
  location: class Poke
12 errors
stdout
Standard output is empty