pythonautomationjythonsikuli

Sikulix install - jython


I need to test unity 3d app on mobile device (or emulator). I do not want to press on buttons using coordinates only, so I want to use Sikuli. I will describe steps that I have already done:

  1. Downloaded and installed Sikuli v1.1.1
  2. Installed java 32bit
  3. Installed jython 2.7.0
  4. jython added as interpreter in my project in pyCharm
  5. sikulixapi is run
  6. Copied Sikuli lib from appData to jython folder
  7. Created Python file and added imports

And when I try to run project I receive this error:

D:\jython2.7.0\bin\jython.exe -Dpython.path=D:\python_projects\sikuli_test D:/python_projects/sikuli_test/test_sikuli.py
Tra**ceback (most recent call last):
  File "D:/python_projects/sikuli_test/test_sikuli.py", line 1, in <module>
    from sikuli import Region
  File "D:\jython2.7.0\Lib\sikuli\__init__.py", line 5, in <module>
    from org.sikuli.basics import Debug
ImportError: No module named sikuli

Process finished with exit code -1**

What am I doing wrong?


Solution

  • The following works for me:

    import org.sikuli.script.SikulixForJython
    

    before

    from sikuli import *