0

我尝试对 sikuli 进行自动测试,我在 sikuli 文件中有很多 TC,但我需要 sikuli 上的所有文件在没有人为操作的情况下一个接一个地运行,我知道我可以做一个批处理或一个运行所有文件的 sukili 文件,但不是一种像 sikuli 中的主要脚本那样做的方法吗?

4

2 回答 2

1

1) Sikuli can use Python modules syntax. I used it in my practice.

My old module was started like this:

# import
import sys
sys.path.append("/Program Files/Sikuli")
from sikuli.Sikuli import *

# some Sikuli functions further.

Then I imported my module like Python module in Sikuli/Python main routine and used it's functions. So you can put your TC in modules and call them from "Main" module.

2) There was some works on integrating Sikuli into Robot Framework, general purpose testing framework. You can Google them out.

Unfortunately, all that worked with Sikuli versions before 1.0 , and I just don't know how it is going now (there is one developer on Sikuli now and things don't go smooth). In general, the answer is "yes, you can" (other way or another), but I can't give clear full details now.

于 2013-08-28T18:51:26.670 回答
0

您可以编写一个 shell 脚本,其中包含您需要手动运行的所有命令。就像是:

#!/bin/sh
sikuli-ide -r sikuli_script1
sikuli-ide -r sikuli_script2
sikuli-ide -r sikuli_script3

等等。之后只需运行脚本。

于 2013-08-26T07:34:20.703 回答