I found a fix to the previous problem by downloading the guava 16.0.1 jar at
https://code.google.com/p/guava-libraries/I have two new problems, changing the test to:
@Test
public void test() {
moveBy(10, 10);
try {
Thread.sleep(500);
} catch (InterruptedException e) {
// TODO Auto-generated catch block
e.printStackTrace();
}
moveBy(10, 10);
}
I get a console printout
[TestFX] User mouse movement detected. Aborting test.
with a stacktrace:
java.lang.ThreadDeath
at java.lang.Thread.stop(Unknown Source)
at org.loadui.testfx.utils.UserInputDetector.userInputDetected(UserInputDetector.java:58)
at org.loadui.testfx.utils.UserInputDetector.assertPointsAreEqual(UserInputDetector.java:42)
at org.loadui.testfx.utils.UserInputDetector.run(UserInputDetector.java:27)
at java.lang.Thread.run(Unknown Source)
I didn't move my mouse at all, the program moved it for me.
if my test method is
@Test
public void test() {
GuiTest click = click(".namefield");
}
I get the stacktrace:
java.lang.NoSuchMethodError: com.google.common.collect.Lists.reverse(Ljava/util/List;)Ljava/util/List;
at org.loadui.testfx.GuiTest.getWindows(GuiTest.java:163)
at org.loadui.testfx.GuiTest.findAllRecursively(GuiTest.java:276)
at org.loadui.testfx.GuiTest.findAll(GuiTest.java:249)
at org.loadui.testfx.GuiTest.findByCssSelector(GuiTest.java:432)
at org.loadui.testfx.GuiTest.find(GuiTest.java:300)
at org.loadui.testfx.GuiTest.pointFor(GuiTest.java:1191)
at org.loadui.testfx.GuiTest.move(GuiTest.java:854)
at org.loadui.testfx.GuiTest.click(GuiTest.java:628)
at test.CreateTestCollectionFromJUnitTest.test(CreateTestCollectionFromJUnitTest.java:44)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
at java.lang.reflect.Method.invoke(Unknown Source)
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.InvokeMethod.evaluate(InvokeMethod.java:17)
at org.junit.internal.runners.statements.RunBefores.evaluate(RunBefores.java:26)
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:467)
I am not sure if "namefield" shoud have a '.' or not, but both variations give the same stack trace error. Can someone help?