简体   繁体   中英

How to run a Sikuli test as a standalone executable

I wrote some Sikuli code in my system using Sikuli IDE. How do I convert this .sikuli file and SikuliX setup to *.exe or *.jar and run in another system?

Just example code in Sikuli IDE:

type(Key.WIN)
type("Internet Explorer"+Key.ENTER)
click(Pattern("1517398787539.png").targetOffset(-41,1))
exit()
type('A', Key.CTRL)
type(Key.DELETE)
type("www.google.com"+Key.ENTER)
exit()

Theoretically you can do both but not directly from IDE. If you're more comfortable with Python, move your script to a standalone .py file and make it do what you want. Then you can use py2exe to convert it into a standalone executable script.

If you want jar then I think you have no other choice than rewriting your script in Java and then pack it into a jar with all the relevant dependencies.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM