2018-11-16 09:53:05 +00:00
|
|
|
import pytest
|
|
|
|
|
2018-11-09 21:26:36 +00:00
|
|
|
try:
|
|
|
|
import org.sikuli.script.SikulixForJython
|
|
|
|
from sikuli import *
|
|
|
|
except Exception:
|
|
|
|
pass
|
|
|
|
|
|
|
|
|
|
|
|
class BaseTestCase:
|
2018-11-16 09:53:05 +00:00
|
|
|
errors = list()
|
2018-11-09 21:26:36 +00:00
|
|
|
|
|
|
|
try:
|
|
|
|
Settings.ActionLogs = 0
|
|
|
|
Settings.MinSimilarity = 0.4
|
|
|
|
except NameError:
|
|
|
|
pass
|
|
|
|
|
|
|
|
def setup_method(self, method):
|
|
|
|
openApp('/home/squashfs-root/AppRun')
|
|
|
|
|
|
|
|
def teardown_method(self, method):
|
|
|
|
pass
|
2018-11-16 09:53:05 +00:00
|
|
|
|
|
|
|
def verify_no_errors(self):
|
|
|
|
if self.errors:
|
|
|
|
pytest.fail('. '.join([self.errors.pop(0) for _ in range(len(self.errors))]))
|