change: update wda logs

This commit is contained in:
debugtalk
2022-09-28 11:50:34 +08:00
parent 732f756778
commit 0d2dd59b4f
10 changed files with 41 additions and 15 deletions

View File

@@ -45,6 +45,18 @@
}
]
},
{
"name": "处理青少年弹窗",
"ios": {
"actions": [
{
"method": "tap_ocr",
"params": "我知道了",
"ignore_NotFoundError": true
}
]
}
},
{
"name": "向上滑动 2 次",
"ios": {

View File

@@ -24,6 +24,12 @@ teststeps:
assert: exists
expect: 推荐
msg: 抖音启动失败,「推荐」不存在
- name: 处理青少年弹窗
ios:
actions:
- method: tap_ocr
params: 我知道了
ignore_NotFoundError: true
- name: 向上滑动 2 次
ios:
actions:

View File

@@ -21,9 +21,9 @@ func TestIOSDouyinLive(t *testing.T) {
SwipeToTapApp("$app_name", hrp.WithMaxRetryTimes(5), hrp.WithIdentifier("启动抖音")).Sleep(5).
Validate().
AssertOCRExists("推荐", "抖音启动失败,「推荐」不存在"),
// hrp.NewStep("处理青少年弹窗").
// IOS().
// TapByOCR("我知道了", hrp.WithIgnoreNotFoundError(true)),
hrp.NewStep("处理青少年弹窗").
IOS().
TapByOCR("我知道了", hrp.WithIgnoreNotFoundError(true)),
hrp.NewStep("向上滑动 2 次").
IOS().
SwipeUp(hrp.WithIdentifier("第一次上划")).Sleep(2).ScreenShot(). // 上划 1 次,等待 2s截图保存