
package org.kuali.rice.krad.labs.lookups;

import org.junit.Test;
import org.openqa.selenium.By;

/**
 * @author Kuali Rice Team (rice.collab@kuali.org)
 */
public class LabsLookupQuickFinderDisabledAft extends LabsLookupBase {

    /**
     * /kr-krad/lookup?methodToCall=start&viewId=LabsLookup-QuickfinderDisabledView&hideReturnLink=true
     */
    public static final String BOOKMARK_URL = "/kr-krad/lookup?methodToCall=start&viewId=LabsLookup-QuickfinderDisabledView&hideReturnLink=true";

    @Override
    protected String getBookmarkUrl() {
        return BOOKMARK_URL;
    }

    @Override
    protected void navigate() throws Exception {
        navigateToLookup("Lookup Quickfinder Disabled");
    }

    @Test
    public void testLabsLookupQuickFinderDisabledBookmark() throws Exception {
        testLabsLookupQuickFinderDisabled();
        passed();
    }

    @Test
    public void testLabsLookupQuickFinderDisabledNav() throws Exception {
        testLabsLookupQuickFinderDisabled();
        passed();
    }
    
    protected void testLabsLookupQuickFinderDisabled()throws Exception {
        waitForElementPresentByXpath("//input[@name='lookupCriteria[number]' and @value='a2']");
        waitForElementNotPresent(By.xpath("//a[@class='icon-search']"));
    }
}
