public IEnumerable <IWebElement> FindElements(string locator) { if (string.IsNullOrWhiteSpace(locator)) { throw new ArgumentNullException("locator"); } var by = ElementLocator.Parse(locator); var elements = this.Driver.FindElements(by); return(elements); }
public IWebElement FindElement(string locator) { if (string.IsNullOrWhiteSpace(locator)) { throw new ArgumentNullException("locator"); } var by = ElementLocator.Parse(locator); var element = this.Driver.FindElement(by); var remoteElement = element as RemoteWebElement; if (null != remoteElement) { var scrollIntoView = remoteElement.LocationOnScreenOnceScrolledIntoView; } this.HighlightElement(element); return(element); }