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

Hi there,
I'm interested by using robot framework with sikuli, but i don't know very much 
how robotframework works:
for example, when i'm using this test:
______________________________________________
*** Settings ***
Library           HelloWorld.py

*** Test Cases ***
HelloWorld
    hello_world

verifyValue
    sbtfct    15

*** Keywords ***
sbtfct
    [Arguments]    ${arg1}
    fct    ${arg1}
______________________________________________

with this code :
_____________________
def hello_world():
   print "HELLO WORLD!"

def fct(v):
   return (v == 15)
_____________________

Both Test PASS, but when i put the last inside a class (classHello), the tests 
FAILS.
here is the code :
_________________________________
from __future__ import with_statement
from sikuli.Sikuli import *

class HelloWorld(object):

   def __init__(self):
      self.valeur = 15
   def hello_world():
      print "HELLO WORLD!"

   def fct(self):
      return (self.valeur == 15)

          
if __name__ == "__main__":
   hww = HelloWorld()
   if (hww.fct()):
      print 'valide'
_________________________________
and i changed the library as follow : Library           HelloWorld.classHello   
 WITH NAME    hwc

It's probably a stupid mistake, but once again, i'm justgetting started with 
robotframwork ...

i'm getting this error : No keyword with name 'hww.hello_world' found.
plus, at the beginning i get : [ ERROR ] Error in file 
'file_path\HelloWorld.txt' in table 'Settings': Importing test library 
'HelloWorld.classHello' failed: TypeError: log(): 1st arg can't be coerced to 
String
Thanks for your time !

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

_______________________________________________
Mailing list: https://launchpad.net/~sikuli-driver
Post to     : [email protected]
Unsubscribe : https://launchpad.net/~sikuli-driver
More help   : https://help.launchpad.net/ListHelp

Reply via email to