Just grabbed from github and updated vaadin-testbench to 4.0.3 and tests stopped working. Some tests fails with:
[code]
org.openqa.selenium.NoSuchElementException: Vaadin could not find elements with the selector (//com.vaadin.ui.Button[caption=“Sign In”]
)[0]
For documentation on this error, please visit: http://seleniumhq.org/exceptions/no_such_element.html
Build info: version: ‘2.46.0’, revision: ‘61506a4624b13675f24581e453592342b7485d71’, time: ‘2015-06-04 10:22:50’
System info: host: ‘localhost.localdomain’, ip: ‘127.0.0.1’, os.name: ‘Linux’, os.arch: ‘amd64’, os.version: ‘4.0.6-200.fc21.x86_64’, java.version: ‘1.8.0_45’
Driver info: driver.version: unknown
at com.vaadin.testbench.TestBenchDriverProxy.executeSearch(TestBenchDriverProxy.java:209)
at com.vaadin.testbench.TestBenchDriverProxy.findElementsByVaadinSelector(TestBenchDriverProxy.java:154)
at com.vaadin.testbench.By$ByVaadin.findElements(By.java:55)
at com.vaadin.testbench.ElementQuery.executeSearch(ElementQuery.java:367)
at com.vaadin.testbench.ElementQuery.get(ElementQuery.java:317)
at com.vaadin.testbench.ElementQuery.first(ElementQuery.java:297)
at com.vaadin.demo.dashboard.tb.pageobjects.TBLoginView.login(TBLoginView.java:16)
at com.vaadin.demo.dashboard.tb.TransactionsViewIT.setUp(TransactionsViewIT.java:24)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:497)
at org.junit.runners.model.FrameworkMethod$1.runReflectiveCall(FrameworkMethod.java:47)
at org.junit.internal.runners.model.ReflectiveCallable.run(ReflectiveCallable.java:12)
at org.junit.runners.model.FrameworkMethod.invokeExplosively(FrameworkMethod.java:44)
at org.junit.internal.runners.statements.RunBefores.evaluate(RunBefores.java:24)
at org.junit.internal.runners.statements.RunAfters.evaluate(RunAfters.java:27)
at org.junit.runners.ParentRunner.runLeaf(ParentRunner.java:271)
at org.junit.runners.BlockJUnit4ClassRunner.runChild(BlockJUnit4ClassRunner.java:70)
at org.junit.runners.BlockJUnit4ClassRunner.runChild(BlockJUnit4ClassRunner.java:50)
at org.junit.runners.ParentRunner$3.run(ParentRunner.java:238)
at org.junit.runners.ParentRunner$1.schedule(ParentRunner.java:63)
at org.junit.runners.ParentRunner.runChildren(ParentRunner.java:236)
at org.junit.runners.ParentRunner.access$000(ParentRunner.java:53)
at org.junit.runners.ParentRunner$2.evaluate(ParentRunner.java:229)
at org.junit.runners.ParentRunner.run(ParentRunner.java:309)
at org.eclipse.jdt.internal.junit4.runner.JUnit4TestReference.run(JUnit4TestReference.java:50)
at org.eclipse.jdt.internal.junit.runner.TestExecution.run(TestExecution.java:38)
at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:459)
at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:675)
at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.run(RemoteTestRunner.java:382)
at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.main(RemoteTestRunner.java:192)
Caused by: org.openqa.selenium.WebDriverException: window.vaadin is undefined
Command duration or timeout: 19 milliseconds
Build info: version: ‘2.46.0’, revision: ‘61506a4624b13675f24581e453592342b7485d71’, time: ‘2015-06-04 10:22:50’
System info: host: ‘localhost.localdomain’, ip: ‘127.0.0.1’, os.name: ‘Linux’, os.arch: ‘amd64’, os.version: ‘4.0.6-200.fc21.x86_64’, java.version: ‘1.8.0_45’
Driver info: org.openqa.selenium.firefox.FirefoxDriver
Capabilities [{applicationCacheEnabled=true, rotatable=false, handlesAlerts=true, databaseEnabled=true, version=39.0, platform=LINUX, nativeEvents=false, acceptSslCerts=true, webStorageEnabled=true, locationContextEnabled=true, browserName=firefox, takesScreenshot=true, javascriptEnabled=true, cssSelectorsEnabled=true}]
Session ID: 4220b8ed-9833-4102-9efa-4ed029f27ad0
at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:62)
at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45)
at java.lang.reflect.Constructor.newInstance(Constructor.java:422)
at org.openqa.selenium.remote.ErrorHandler.createThrowable(ErrorHandler.java:204)
at org.openqa.selenium.remote.ErrorHandler.throwIfResponseFailed(ErrorHandler.java:156)
at org.openqa.selenium.remote.RemoteWebDriver.execute(RemoteWebDriver.java:605)
at org.openqa.selenium.remote.RemoteWebDriver.executeScript(RemoteWebDriver.java:514)
at com.vaadin.testbench.commands.TestBenchCommandExecutor.executeScript(TestBenchCommandExecutor.java:350)
at com.vaadin.testbench.TestBenchDriverProxy_$$_jvst92f_0.d9executeScript(TestBenchDriverProxy$$jvst92f_0.java)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:497)
at com.vaadin.testbench.DriverInvocationHandler.invoke(DriverInvocationHandler.java:62)
at com.vaadin.testbench.TestBenchDriverProxy$$jvst92f_0.executeScript(TestBenchDriverProxy$$_jvst92f_0.java)
at com.vaadin.testbench.TestBenchDriverProxy.executeSearch(TestBenchDriverProxy.java:200)
… 31 more
Caused by: org.openqa.selenium.WebDriverException: window.vaadin is undefined
Build info: version: ‘2.46.0’, revision: ‘61506a4624b13675f24581e453592342b7485d71’, time: ‘2015-06-04 10:22:50’
System info: host: ‘localhost.localdomain’, ip: ‘127.0.0.1’, os.name: ‘Linux’, os.arch: ‘amd64’, os.version: ‘4.0.6-200.fc21.x86_64’, java.version: ‘1.8.0_45’
Driver info: driver.version: unknown
at .anonymous(about:neterror?e=connectionFailure&u=http%3A//localhost%3A8080/quicktickets-dashboard%3FrestartApplication%3Dtrue&c=UTF-8&f=regular&d=Firefox%20can%27t%20establish%20a%20connection%20to%20the%20server%20at%20localhost%3A8080. line 69 > Function:1)
at .handleEvaluateEvent(about:neterror?e=connectionFailure&u=http%3A//localhost%3A8080/quicktickets-dashboard%3FrestartApplication%3Dtrue&c=UTF-8&f=regular&d=Firefox%20can%27t%20establish%20a%20connection%20to%20the%20server%20at%20localhost%3A8080.:69)
[/code]Test log:
Tests run: 1, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 13.298 sec
Running com.vaadin.demo.dashboard.tb.TransactionsViewIT
Tests run: 2, Failures: 0, Errors: 2, Skipped: 0, Time elapsed: 8.549 sec <<< FAILURE!
Running com.vaadin.demo.dashboard.tb.LoginViewIT
Tests run: 1, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 6.36 sec
Running com.vaadin.demo.dashboard.tb.DashboardViewIT
Tests run: 2, Failures: 0, Errors: 2, Skipped: 0, Time elapsed: 8.505 sec <<< FAILURE!
Running com.vaadin.demo.dashboard.tb.ReportsViewIT
Tests run: 2, Failures: 0, Errors: 2, Skipped: 0, Time elapsed: 8.373 sec <<< FAILURE!
Results :
Tests in error:
testCreateReport(com.vaadin.demo.dashboard.tb.TransactionsViewIT): Element is not currently visible and so may not be interacted with(..)
testFilter(com.vaadin.demo.dashboard.tb.TransactionsViewIT): Element is not currently visible and so may not be interacted with(..)
testEditDashboardTitle(com.vaadin.demo.dashboard.tb.DashboardViewIT): Element is not currently visible and so may not be interacted with(..)
testReadNotifications(com.vaadin.demo.dashboard.tb.DashboardViewIT): Element is not currently visible and so may not be interacted with(..)
testReportsTextBlock(com.vaadin.demo.dashboard.tb.ReportsViewIT): Element is not currently visible and so may not be interacted with(..)
testReportsInMenu(com.vaadin.demo.dashboard.tb.ReportsViewIT): Element is not currently visible and so may not be interacted with(..)
Tests run: 8, Failures: 0, Errors: 6, Skipped: 0
If I change original pom (testbench 4.0.0.rc1) to exclude selenium and include it myself, it works perfect.
Any advise? Should I post this in another place?
Thanks