How to integrate Sikuli scripts into Selenium?

偶尔善良 提交于 2019-12-02 22:51:58

See the Python section of the Selenium RC documentation: http://seleniumhq.org/docs/05_selenium_rc.html#python

You may be able to run Selenium tests from Jython. In that case, you can simply integrate Selenium scripts into your Sikuli scripts.

Try the following in the Sikuli IDE. You may need to modify the import statements to point to specific files in the Selenium project.

from selenium import selenium    # this will probably need tweaking...

slm = selenium("localhost", 4444, "*firefox", "http://www.google.com/")
slm.start()
# etc...

This guy appears to have had success controlling Selenium from Jython: http://adam.goucher.ca/?p=367

My conclusion: it will probably be easiest to stay in Jython and control Selenium from there. You could integrate both tools into a single script.

It is possible to have Sikuli capabilities on Selenium Grid. It requires extra libraries to be installed on every node and hub.

Check this project to learn more

https://github.com/sterodium/selenium-grid-extensions

If one doesn't need to use custom or specific test framework, one option is Robot Framework (RF). It has a Selenium library, and there is a how to on how to use Sikuli with RF. With that in mind, you could combine the two together using RF. Plus RF has some nice test automation framework features built in.

robotframework.org

http://blog.mykhailo.com/2011/02/how-to-sikuli-and-robot-framework.html

http://code.google.com/p/robotframework-seleniumlibrary

Sergii Pozharov

You can extend the Selenium Server so it will be able to execute SIKULI scripts (see this on how to call them from Java).

However you will need to develop in Java as Selenium Server is a Java app.

If you want to run Sikuli functions remotely on a Selenium Grid, then it seems like you would have to do it with Selenium Augmenter somehow. None of the answers here show how a remote Grid, such as with using SauceLabs, would acquire Sikuli functionality. Perhaps the Selenium project has yet to augment the Augmenter class to load external libraries like Sikuli?

For this reason, when I use Sikuli, I always have to use a non-remote , standard, local, WebDriver instance.

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!