Using Sikuli in Maven projects
-------
With version 1.0.1 and later, it is recommended, to use sikuli-java.jar with Java programming.
Use option 3 with setup and rename the resulting sikuli-java.jar to
sikuli-
and load it into your local Maven repository to use this dependency:
<dependency>
<groupId>
<artifactId>
<version>
</dependency>
-------
the rest of this thread is related to RC3 !!
-------
I am currently using Sikuli and really liking what I see. I have created a Maven project from within Eclipse. Within this project I've setup a POM file that leverages Cucumber-jvm as a dependency. I'm using Cucumber in conjunction with Sikuli to test a Windows app. So, far things are working well. When I want to run my tests, I do so from Eclipse using a JUnit test. I'm using the built-in Windows control panel application (control.exe) as the application under test. Here is a sample of my code
public class ControlPanelSte
private String executable = "control.exe";
private Screen scrn;
private Match match;
@Before
public void setup() {
scrn = new Screen();
}
@After
public void teardown() {
try {
scrn.
} catch (FindFailed e) {
e.printStack
}
}
@Given("^a user wants to access their Windows programs$")
public void a_user_
// Express the Regexp above with the code you wish you had
}
@When("^the user opens the control panel$")
public void the_user_
App.open(
}
@When("^selects Programs from the computer's settings$")
public void selects_
try {
scrn.
} catch (FindFailed e) {
e.printStack
}
}
@Then("^the Programs view is displayed$")
public void the_Programs_
match = scrn.exists(
Assert.
}
}
When I run my test from the command-line using Maven like so
mvn clean test
It reports back that it cannot compile my code. I'm thinking that because the sikuli-script.jar file was added to the project as an external jar, it cannot compile the code because Maven can't find the jar in its local repositories. Has anyone encountered something like this. How would I run my project from the command line using Maven?
Question information
- Language:
- English Edit question
- Status:
- Solved
- For:
- SikuliX Edit question
- Assignee:
- RaiMan Edit question
- Solved by:
- Robert Stagner
- Solved:
- Last query:
- Last reply: