package ru.stqa.pft.addressbook.appmanager;

import org.openqa.selenium.By;
import org.openqa.selenium.WebDriver;
import org.openqa.selenium.firefox.FirefoxDriver;

/**
 * Created by jane on 10/31/16.
 */
public class NavigationHelper extends HelperBase{

  public NavigationHelper(WebDriver wd) {
    super(wd);
  }

  public void gotoGroupPage() {
    click(By.linkText("groups"));
  }

  public void goToHomePage() {
    click(By.linkText("home"));
    }
}

@@ -335,32 +335,220 @@
 toGroupPage() %7B%0A
+    if (isElementPresent(By.tagName(%22h1%22))%0A            && wd.findElement(By.tagName(%22h1%22)).getText().equals(%22Group%22)%0A            && isElementPresent(By.name(%22new%22))) %7B%0A      return;%0A    %7D%0A
     click(By.lin
@@ -565,16 +565,18 @@
 ups%22));%0A
+  
   %7D%0A%0A  p
@@ -599,24 +599,92 @@
 omePage() %7B%0A
+    if (isElementPresent(By.id(%22maintable%22))) %7B%0A      return;%0A    %7D%0A
     click(By

Check if GoTo needed