← Back to team overview

sikuli-driver team mailing list archive

[Question #173899]: Robot Framework Problem

 

New question #173899 on Sikuli:
https://answers.launchpad.net/sikuli/+question/173899

Hi.

I followed the instructions on http://blog.mykhailo.com/2011/02/how-to-sikuli-and-robot-framework.html but am having some problems with Robot Framework.

Here is the information on my system:
- Windows XP Service Pack 3
- Java Runtime Environment (JRE 6_27)
- Jython 2.5.2
- Python 2.7.2
- Robot Framework 2.5.5
- Sikuli X 1.0rc3

My robottest.bat looks like the following:
@echo off
set sikuli_jar=D:\Program Files\Sikuli X\sikuli-script.jar
java -cp "robotframework-2.5.5.jar;%sikuli_jar%" ^
     -Dpython.path=..\robotframework-2.5.5.jar\Lib;"%sikuli_jar%/Lib" ^
     org.robotframework.RobotFramework ^
     --pythonpath=calc.sikuli ^
     --outputdir=results ^
     --loglevel=TRACE ^
     %*

When I run it, I get following message:
D:\Sikuli\RobotFramework> robottest.bat robot_suite\verify_operations.txt
Exception in thread "main" Traceback (most recent call last):
  File "<string>", line 1, in <module>
  File "D:\Sikuli\RobotFramework\robotframework-2.5.5.jar\Lib\robot\__init__$py.class", line 16, in <module>
  File "D:\Program Files\Sikuli X\sikuli-script.jar\Lib\os.py", line 118, in <module>
ImportError: no os specific module found

I run test using jybot.bat, which looks like following:
@echo off
set sikuli_jar=D:\Program Files\Sikuli X\sikuli-script.jar
set CLASSPATH=%sikuli_jar%
set JYTHONPATH=%sikuli_jar%/Lib
jybot --pythonpath=calc.sikuli ^
      --outputdir=results ^
      --loglevel=TRACE ^
      %*

I get the following message:
D:\Sikuli\RobotFramework>jybottest.bat robot_suite\verify_operations.txt

[ ERROR ] Invalid syntax in file 'd:\sikuli\robotframework\robot_suite\verify_operations.txt' in table 'Settings': 
Importing test library 'calc.Calculator' failed:
SyntaxError: 'with' will become a reserved keyword in Python 2.6 (calc.py, line 37)
PYTHONPATH: [u'calc.sikuli', 'D:\\Python27\\Lib\\site-packages', 'D:\\Python27\\Lib\\site-packages\\robot\\libraries','D:\\Program Files\\Sikuli X\\sikuli-script.jar\\Lib', 'D:\\jython2.5.2\\Lib', '__classpath__','__pyclasspath__/', 'D:\\jython2.5.2\\Lib\\site-packages', '.']
CLASSPATH: D:\jython2.5.2\jython.jar;D:\Program Files\Sikuli X\sikuli-script.jar

Traceback (most recent call last):
  File "D:\Python27\Lib\site-packages\robot\utils\importing.py", line 88, in _import
    imported = __import__(modname, {}, {}, fromlist)
  File "D:\Python27\Lib\site-packages\robot\utils\importing.py", line 88, in _import
    imported = __import__(modname, {}, {}, fromlist)
==============================================================================
Verify Operations
==============================================================================
Verify that 2 + 2 = 4                                                 | FAIL |
No keyword with name 'Start App' found.
------------------------------------------------------------------------------
Verify that 2 + 2 = 5                                                 | FAIL |
No keyword with name 'Start App' found.
------------------------------------------------------------------------------
Verify Operations                                                     | FAIL |
2 critical tests, 0 passed, 2 failed
2 tests total, 0 passed, 2 failed
==============================================================================
Output:  d:\sikuli\robotframework\results\output.xml
Report:  d:\sikuli\robotframework\results\report.html
Log:     d:\sikuli\robotframework\results\log.html


-- 
You received this question notification because you are a member of
Sikuli Drivers, which is an answer contact for Sikuli.