@@ -123,14 +123,41 @@ export class EngineClient {
123123 return this . _get < unknown [ ] > ( `/api/v1/memory/history${ qs ? "?" + qs : "" } ` ) ;
124124 }
125125
126- /** 蓝本模式测试(v2.3) */
126+ /** Web 蓝本模式测试 */
127127 async startBlueprintTest ( params : {
128128 blueprint_path : string ;
129129 base_url ?: string ;
130130 } ) : Promise < TestReportResponse > {
131131 return this . _post < TestReportResponse > ( "/api/v1/test/blueprint" , params ) ;
132132 }
133133
134+ /** 手机蓝本测试(Android/iOS) */
135+ async startMobileBlueprintTest ( params : {
136+ blueprint_path : string ;
137+ base_url ?: string ;
138+ mobile_session_id : string ;
139+ } ) : Promise < TestReportResponse > {
140+ return this . _post < TestReportResponse > ( "/api/v1/test/mobile-blueprint" , params ) ;
141+ }
142+
143+ /** 小程序蓝本测试 */
144+ async startMiniprogramBlueprintTest ( params : {
145+ blueprint_path : string ;
146+ base_url ?: string ;
147+ project_path ?: string ;
148+ } ) : Promise < TestReportResponse > {
149+ return this . _post < TestReportResponse > ( "/api/v1/test/miniprogram-blueprint" , params ) ;
150+ }
151+
152+ /** 桌面蓝本测试 */
153+ async startDesktopBlueprintTest ( params : {
154+ blueprint_path : string ;
155+ base_url ?: string ;
156+ window_title ?: string ;
157+ } ) : Promise < TestReportResponse > {
158+ return this . _post < TestReportResponse > ( "/api/v1/test/desktop-blueprint" , params ) ;
159+ }
160+
134161 /** 蓝本自动生成(v10.1) */
135162 async generateBlueprint ( params : {
136163 url : string ;
@@ -159,6 +186,32 @@ export class EngineClient {
159186 return this . _get < TestStatus > ( "/api/v1/test/status" ) ;
160187 }
161188
189+ /** 列出已连接移动设备 */
190+ async listMobileDevices ( ) : Promise < { devices : Array < Record < string , unknown > > ; count : number ; error ?: string } > {
191+ return this . _get < { devices : Array < Record < string , unknown > > ; count : number ; error ?: string } > ( "/api/v1/mobile/devices" ) ;
192+ }
193+
194+ /** 列出活动移动会话 */
195+ async listMobileSessions ( ) : Promise < { sessions : Array < Record < string , unknown > > ; count : number } > {
196+ return this . _get < { sessions : Array < Record < string , unknown > > ; count : number } > ( "/api/v1/mobile/sessions" ) ;
197+ }
198+
199+ /** 创建移动会话 */
200+ async createMobileSession ( params : {
201+ device_name ?: string ;
202+ app_package ?: string ;
203+ app_activity ?: string ;
204+ app_path ?: string ;
205+ permissions ?: string [ ] ;
206+ } = { } ) : Promise < { session_id : string ; message : string ; device ?: Record < string , unknown > } > {
207+ return this . _post < { session_id : string ; message : string ; device ?: Record < string , unknown > } > ( "/api/v1/mobile/session/create" , params ) ;
208+ }
209+
210+ /** 检查小程序开发者工具状态 */
211+ async getMiniprogramDevtoolsStatus ( ) : Promise < { found : boolean ; path ?: string ; message ?: string } > {
212+ return this . _get < { found : boolean ; path ?: string ; message ?: string } > ( "/api/v1/miniprogram/devtools/status" ) ;
213+ }
214+
162215 /** 测试控制:暂停/继续/停止(v2.0) */
163216 async controlTest ( action : string ) : Promise < { action : string ; success : boolean ; state : string } > {
164217 return this . _post < { action : string ; success : boolean ; state : string } > (
0 commit comments