All Downloads are FREE. Search and download functionalities are using the official Maven repository.

nl.hsac.fitnesse.fixture.util.selenium.by.TitleBy Maven / Gradle / Ivy

There is a newer version: 5.3.17
Show newest version
package nl.hsac.fitnesse.fixture.util.selenium.by;

import org.openqa.selenium.By;

/**
 * Finds elements based on their title (aka tooltip).
 */
public class TitleBy {
    /**
     * @param text exact title value.
     * @return by returning element with supplied title attribute.
     */
    public static By exact(String text) {
        return new CssBy("[title='%s']", text);
    }

    /**
     * @param text partial title value.
     * @return by returning element whose title attribute contains supplied text.
     */
    public static By partial(String text) {
        return new CssBy("[title*='%s']", text);
    }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy