You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Currently TabElement.getText(), and consequently anything relying on the return value of that method, is broken when running tests using the latest Firefox. Instead of returning the tab title, the value is just empty.
Apparently this problem isn't limited to just the TabElement, it might just be that pretty much anything using getText() is not working correctly.
Steps to reproduce
To reproduce, get a Vaadin 23 skeleton starter project from start.vaadin.com, and add the following to the MainView class:
Tabs tabs = new Tabs();
tabs.add(new Tab("About"));
tabs.add(new Tab("Info"));
add(tabs);
Change the WebDriver in use from ChromeDriver to FirefoxDriver in AbstractTestView, run the application, and add the following test to the MainViewIT class and run it:
@Test
public void testTabs() {
TabsElement tabs = $(TabsElement.class).waitForFirst();
String title = tabs.getSelectedTabElement().getText();
int index = tabs.getTab("About");
System.out.println("About tab's index is " + index);
System.out.println("Selected tab's title text is " + title);
}
You will end up with return values of "-1" and "". If you use tabs.getSelectedTabElement().getWrappedElement().getDomProperty("innerHTML"); you will get the Tab title, but of course the tabs.getTab("About"); will return -1 no matter what.
Expected result
The tab text and the tab index are returned properly. This happens when testing with Chrome or Safari.
Versions
macOS Sonoma 14.2
Verified with Vaadin 23.3.29, I would expect this to be similarly broken with Vaadin 24.
Firefox 120.0.1
The text was updated successfully, but these errors were encountered:
Problem
Currently TabElement.getText(), and consequently anything relying on the return value of that method, is broken when running tests using the latest Firefox. Instead of returning the tab title, the value is just empty.
Apparently this problem isn't limited to just the TabElement, it might just be that pretty much anything using getText() is not working correctly.
Steps to reproduce
To reproduce, get a Vaadin 23 skeleton starter project from start.vaadin.com, and add the following to the MainView class:
Change the WebDriver in use from ChromeDriver to FirefoxDriver in AbstractTestView, run the application, and add the following test to the MainViewIT class and run it:
You will end up with return values of "-1" and "". If you use
tabs.getSelectedTabElement().getWrappedElement().getDomProperty("innerHTML");
you will get the Tab title, but of course thetabs.getTab("About");
will return -1 no matter what.Expected result
The tab text and the tab index are returned properly. This happens when testing with Chrome or Safari.
Versions
macOS Sonoma 14.2
Verified with Vaadin 23.3.29, I would expect this to be similarly broken with Vaadin 24.
Firefox 120.0.1
The text was updated successfully, but these errors were encountered: