java - Why WebElement and List<WebElement> are processed not in the similar way via xpath and List is always null? -


i'm using thucydides 0.9.229 selenium shipped it. obtain webelements try them via list

@findall({@findby(xpath = "//div[text()='Расположение']/../../td[2]//input[@type='text']")}) private list<webelement> placement; 

with no result, placement returned null, while here

@findby(xpath = "//div[text()='Расположение']/../../td[2]//input[@type='text']")}) private webelement placement; 

there placement not null, correct webelement handled well. far understand, firs example should return 1-value list anyway, more values if there additional elements fitting criteria. so, wrong, why can't list of webelements there?

i have same issue @findall, , returns null.

however, can use @findby list of elements too. may used mark field on page object indicate element or list of elements.

@findby(xpath = "//div[text()='Расположение']/../../td[2]//input[@type='text']")}) private list<webelement> placement; 

Comments

Popular posts from this blog

google api - Incomplete response from Gmail API threads.list -

Installing Android SQLite Asset Helper -

Qt Creator - Searching files with Locator including folder -