You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Originally posted by Hades69 June 2, 2024
Please let me know how to solve this Error, even my code is right, it still show this Error code.
I'm using newest Poco and AirTest IDE
Here is my code:
# -*- encoding=utf8 -*-
__author__ = "hoang"
from airtest.core.api import *
from airtest.cli.parser import cli_setup
if not cli_setup():
auto_setup(__file__, logdir=True, devices=["android://127.0.0.1:5037/6743c116?cap_method=ADBCAP&touch_method=MAXTOUCH&",])
from poco.drivers.unity3d import UnityPoco
poco = UnityPoco()
# script content
print("start...")
stop_app("com.wood.nut.and.bolts.puzzle")
start_app("com.wood.nut.and.bolts.puzzle")
sleep(7)
def check_object_text(obj, expected_text):
if not obj.exists():
return False
actual_text = obj.get_text()
if actual_text == expected_text:
return True
else:
return False
button = poco( textMatches = "CONNEXION QUOTIDIENNE")
if check_object_text(button, 'CONNEXION QUOTIDIENNE'):
print('Text matches')
else:
print('Text not matches')
# generate html report
# from airtest.report.report import simple_report
# simple_report(__file__, logpath=True)</div>
The text was updated successfully, but these errors were encountered:
Discussed in #4574
Originally posted by Hades69 June 2, 2024
Please let me know how to solve this Error, even my code is right, it still show this Error code.
I'm using newest Poco and AirTest IDE
Here is my code:
The text was updated successfully, but these errors were encountered: