-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathFirefoxTest.java
More file actions
40 lines (27 loc) · 873 Bytes
/
FirefoxTest.java
File metadata and controls
40 lines (27 loc) · 873 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
package com.github.selenium;
import static org.junit.Assert.assertEquals;
import java.util.concurrent.TimeUnit;
import org.junit.After;
import org.junit.Before;
import org.junit.Test;
import org.openqa.selenium.WebDriver;
import org.openqa.selenium.firefox.FirefoxDriver;
public class FirefoxTest {
private static final String BASE_PATH = "https://github.com/hemantsonu20";
private WebDriver driver;
@Before
public void setUpDriver() {
driver = new FirefoxDriver();
driver.manage().window().maximize();
driver.manage().timeouts().implicitlyWait(10, TimeUnit.SECONDS);
}
@After
public void tearDownDriver() {
driver.quit();
}
@Test
public void openGithubProfile() {
driver.get(BASE_PATH);
assertEquals("hemantsonu20 (Pratapi Hemant) · GitHub", driver.getTitle());
}
}