package com.opera.core.systems;

import org.junit.Assert;
import org.junit.Test;

public class NavigationTest extends TestBase
{
  @Test
  public void testBack()
  {
	  getFixture("javascript.html");
	  getFixture("test.html");
	  getFixture("keys.html");

	  driver.navigate().back();
	  Assert.assertTrue(driver.getCurrentUrl().indexOf("test.html") > 0);
  }

  @Test
  public void testForward()
  {
    driver.navigate().forward();
    Assert.assertTrue(driver.getCurrentUrl().indexOf("keys.html") > 0);
  }

  @Test
  public void testBack2()
  {
	  driver.navigate().back();
	  driver.navigate().back();
	  Assert.assertTrue(driver.getCurrentUrl().indexOf("javascript.html") > 0);
  }

  @Test
  public void testForward2()
  {
    driver.navigate().forward();
    driver.navigate().forward();
    Assert.assertTrue(driver.getCurrentUrl().indexOf("keys.html") > 0);
  }
}

@@ -866,10 +866,315 @@
 0);%0A  %7D%0A
+  %0A  @Test%0A  public void testHttpRedirect() throws Exception %7B%0A    driver.get(%22http://t/core/bts/javascript/CORE-26410/003-2.php%22);%0A    %0A    // Wait for redirect%0A    Thread.sleep(1000);%0A    %0A    Assert.assertEquals(%22http://t/core/bts/javascript/CORE-26410/001-3.php%22,%0A        driver.getCurrentUrl());%0A  %7D%0A
 %7D%0A

Add test for page that redirects