feat: dev-5.1 分支基线(v1.3.35 发版后代码 + 5.1 声道改造文档)
- 以 main(ccc65af) 为基线提交当前工作区代码
- 新增 5.1 声道改造文档两份
- .gitignore 补充 .vscode/、.screenshots/
This commit is contained in:
88
test/voice_helper/run_all.sh
Normal file
88
test/voice_helper/run_all.sh
Normal file
@@ -0,0 +1,88 @@
|
||||
#!/usr/bin/env bash
|
||||
# run_all.sh - 一键顺序执行全部用例
|
||||
# 适用于联调验证:冷启动 -> 单片跳转(应进入播放页)-> 节流 -> 全屏 -> 分类跳转 -> 搜索 -> 安全 -> 创维链路
|
||||
# 用法: run_all.sh [all|unified|skyworth]
|
||||
# all 全部执行(默认,统一协议 + 创维)
|
||||
# unified 只跑统一协议链路(VoiceCommandReceiver)
|
||||
# skyworth 只跑创维链路(SkyworthVoiceAdapter)
|
||||
|
||||
set -e
|
||||
SCRIPT_DIR="$(cd "$(dirname "$0")" && pwd)"
|
||||
# shellcheck disable=SC1091
|
||||
source "${SCRIPT_DIR}/lib/common.sh"
|
||||
|
||||
require_adb
|
||||
check_receiver_exists
|
||||
|
||||
SCOPE="${1:-all}"
|
||||
|
||||
run_unified() {
|
||||
print_header "Run All: 冷启动 -> 单片跳转 -> 节流 -> 全屏 -> 分类 -> 搜索 -> 安全"
|
||||
log_warn "各步骤之间会 sleep 等待页面稳定,请勿中途打断"
|
||||
|
||||
# 1. 冷启动单片跳转(force-stop + 投递 + 拉起)
|
||||
"${SCRIPT_DIR}/cold_start.sh"
|
||||
sleep 5
|
||||
|
||||
# 2. 节流测试(需在播放页)
|
||||
"${SCRIPT_DIR}/throttle_test.sh" PAUSE 5
|
||||
sleep 2
|
||||
|
||||
# 3. 全屏切换
|
||||
"${SCRIPT_DIR}/control.sh" FULLSCREEN_ENTER
|
||||
sleep 2
|
||||
"${SCRIPT_DIR}/control.sh" FULLSCREEN_EXIT
|
||||
sleep 2
|
||||
|
||||
# 4. 分类跳转(会退出播放态)
|
||||
"${SCRIPT_DIR}/jump_category.sh"
|
||||
sleep 3
|
||||
|
||||
# 5. 语音搜索
|
||||
"${SCRIPT_DIR}/search.sh" "测试片"
|
||||
sleep 3
|
||||
|
||||
# 6. 安全校验(非白名单 sourceApp)
|
||||
"${SCRIPT_DIR}/security_test.sh"
|
||||
sleep 1
|
||||
}
|
||||
|
||||
run_skyworth() {
|
||||
print_header "Run Skyworth: 创维 VOD 链路(正常 -> 空候选 -> 多候选 -> 安全 -> 冷启动)"
|
||||
|
||||
# 1. 正常点播(白名单 sender + 有效片名)
|
||||
"${SCRIPT_DIR}/skyworth_vod.sh"
|
||||
sleep 3
|
||||
|
||||
# 2. 空候选(应 dropped)
|
||||
"${SCRIPT_DIR}/skyworth_empty_test.sh" empty
|
||||
sleep 2
|
||||
|
||||
# 3. 多候选跳空(应取首个非空)
|
||||
"${SCRIPT_DIR}/skyworth_empty_test.sh" multi
|
||||
sleep 3
|
||||
|
||||
# 4. 安全校验(非白名单 sender,应 dropped)
|
||||
"${SCRIPT_DIR}/skyworth_security_test.sh"
|
||||
sleep 2
|
||||
|
||||
# 5. 冷启动(force-stop + 排队 + 回放)
|
||||
"${SCRIPT_DIR}/skyworth_cold_start.sh"
|
||||
}
|
||||
|
||||
case "${SCOPE}" in
|
||||
unified) run_unified ;;
|
||||
skyworth) run_skyworth ;;
|
||||
all)
|
||||
run_unified
|
||||
sleep 3
|
||||
run_skyworth
|
||||
;;
|
||||
*)
|
||||
echo "用法: $0 [all|unified|skyworth]" >&2
|
||||
exit 1
|
||||
;;
|
||||
esac
|
||||
|
||||
print_header "全部用例执行完毕"
|
||||
log_ok "请结合 logcat / dumpsys 验证执行链路与回传"
|
||||
Reference in New Issue
Block a user