mirror of
https://github.com/httprunner/httprunner.git
synced 2026-05-25 18:30:04 +08:00
98 lines
3.5 KiB
JSON
98 lines
3.5 KiB
JSON
{
|
||
"config": {
|
||
"name": "抓取 KS 视频信息",
|
||
"variables": {
|
||
"device": "${ENV(SerialNumber)}"
|
||
},
|
||
"android": [
|
||
{
|
||
"serial": "$device"
|
||
}
|
||
]
|
||
},
|
||
"teststeps": [
|
||
{
|
||
"name": "滑动消费 feed 至少 100 个;滑动过程中,70% 随机间隔 0-5s,30% 随机间隔 5-10s",
|
||
"android": {
|
||
"actions": [
|
||
{
|
||
"method": "video_crawler",
|
||
"params": {
|
||
"app_package_name": "com.smile.gifmaker",
|
||
"feed": {
|
||
"sleep_random": [
|
||
0,
|
||
5,
|
||
0.7,
|
||
5,
|
||
10,
|
||
0.3
|
||
],
|
||
"target_count": 100,
|
||
"target_labels": [
|
||
{
|
||
"regex": true,
|
||
"scope": [
|
||
0,
|
||
0.5,
|
||
1,
|
||
1
|
||
],
|
||
"text": "^广告$"
|
||
},
|
||
{
|
||
"regex": true,
|
||
"scope": [
|
||
0,
|
||
0.5,
|
||
1,
|
||
1
|
||
],
|
||
"text": "^推广$"
|
||
},
|
||
{
|
||
"regex": true,
|
||
"scope": [
|
||
0,
|
||
0.5,
|
||
1,
|
||
1
|
||
],
|
||
"text": "^磁力广告$"
|
||
}
|
||
]
|
||
},
|
||
"live": {
|
||
"sleep_random": [
|
||
15,
|
||
20
|
||
],
|
||
"target_count": 0
|
||
},
|
||
"timeout": 3600
|
||
}
|
||
}
|
||
]
|
||
}
|
||
},
|
||
{
|
||
"name": "exit",
|
||
"android": {
|
||
"actions": [
|
||
{
|
||
"method": "app_terminate",
|
||
"params": "com.smile.gifmaker"
|
||
}
|
||
]
|
||
},
|
||
"validate": [
|
||
{
|
||
"check": "ui_foreground_app",
|
||
"assert": "not_equal",
|
||
"expect": "com.smile.gifmaker",
|
||
"msg": "app [com.smile.gifmaker] should not be in foreground"
|
||
}
|
||
]
|
||
}
|
||
]
|
||
} |