package ru.stqa.selenium;

import org.openqa.selenium.support.ui.WebDriverWait;
import org.testng.annotations.*;
import static org.testng.Assert.*;
import org.openqa.selenium.*;

import java.util.concurrent.TimeUnit;

public class LoginTest extends TestNgTestBase{

  @Test
  public void testLogin() throws Exception {
    driver.get(baseUrl + "/php4dvd/");
    driver.findElement(By.id("username")).clear();
    driver.findElement(By.id("username")).sendKeys("admin");
    driver.findElement(By.name("password")).clear();
    driver.findElement(By.name("password")).sendKeys("admin");
    driver.findElement(By.name("submit")).click();
    assertEquals(driver.findElement(By.xpath("//title")).getText(), " My movie collection - php4dvd v2.0 ");
  }
}
@@ -35,186 +35,60 @@
 org.
-openqa.selenium.support.ui.WebDriverWait;%0Aimport org.testng.annotations.*;%0Aimport static org.testng.Assert.*;%0Aimport org.openqa.selenium.*;%0A%0Aimport java.util.concurrent.TimeUnit;
+testng.annotations.*;%0Aimport org.openqa.selenium.*;%0A
 %0A%0Apu
@@ -150,16 +150,23 @@
  public 
+static 
 void tes
@@ -172,16 +172,32 @@
 stLogin(
+WebDriver driver
 ) throws
@@ -531,117 +531,8 @@
 ();%0A
-    assertEquals(driver.findElement(By.xpath(%22//title%22)).getText(), %22 My movie collection - php4dvd v2.0 %22);%0A
   %7D%0A

make method testLogin static