mirror of
https://github.com/httprunner/httprunner.git
synced 2026-06-08 09:19:41 +08:00
feat: support action options for AppLaunch/AppTerminate
This commit is contained in:
14
step_ui.go
14
step_ui.go
@@ -91,18 +91,20 @@ func (s *StepMobile) WebLoginNoneUI(packageName, phoneNumber string, captcha, pa
|
||||
return s
|
||||
}
|
||||
|
||||
func (s *StepMobile) AppLaunch(bundleId string) *StepMobile {
|
||||
func (s *StepMobile) AppLaunch(bundleId string, opts ...option.ActionOption) *StepMobile {
|
||||
s.obj().Actions = append(s.obj().Actions, uixt.MobileAction{
|
||||
Method: uixt.ACTION_AppLaunch,
|
||||
Params: bundleId,
|
||||
Method: uixt.ACTION_AppLaunch,
|
||||
Params: bundleId,
|
||||
Options: option.NewActionOptions(opts...),
|
||||
})
|
||||
return s
|
||||
}
|
||||
|
||||
func (s *StepMobile) AppTerminate(bundleId string) *StepMobile {
|
||||
func (s *StepMobile) AppTerminate(bundleId string, opts ...option.ActionOption) *StepMobile {
|
||||
s.obj().Actions = append(s.obj().Actions, uixt.MobileAction{
|
||||
Method: uixt.ACTION_AppTerminate,
|
||||
Params: bundleId,
|
||||
Method: uixt.ACTION_AppTerminate,
|
||||
Params: bundleId,
|
||||
Options: option.NewActionOptions(opts...),
|
||||
})
|
||||
return s
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user