mirror of
https://github.com/httprunner/httprunner.git
synced 2026-08-28 19:47:14 +08:00
introduce expert test for both integration and regression
This commit is contained in:
+14
-2
@@ -102,7 +102,7 @@ func (s *StepMobile) Tap(params string, options ...uixt.ActionOption) *StepMobil
|
||||
return &StepMobile{step: s.step}
|
||||
}
|
||||
|
||||
// Tap taps on the target element by OCR recognition
|
||||
// TapByOCR taps on the target element by OCR recognition
|
||||
func (s *StepMobile) TapByOCR(ocrText string, options ...uixt.ActionOption) *StepMobile {
|
||||
action := uixt.MobileAction{
|
||||
Method: uixt.ACTION_TapByOCR,
|
||||
@@ -114,7 +114,7 @@ func (s *StepMobile) TapByOCR(ocrText string, options ...uixt.ActionOption) *Ste
|
||||
return &StepMobile{step: s.step}
|
||||
}
|
||||
|
||||
// Tap taps on the target element by CV recognition
|
||||
// TapByCV taps on the target element by CV recognition
|
||||
func (s *StepMobile) TapByCV(imagePath string, options ...uixt.ActionOption) *StepMobile {
|
||||
action := uixt.MobileAction{
|
||||
Method: uixt.ACTION_TapByCV,
|
||||
@@ -126,6 +126,18 @@ func (s *StepMobile) TapByCV(imagePath string, options ...uixt.ActionOption) *St
|
||||
return &StepMobile{step: s.step}
|
||||
}
|
||||
|
||||
// TapByUITypes taps on the target element specified by uiTypes, the higher the uiTypes, the higher the priority
|
||||
func (s *StepMobile) TapByUITypes(uiTypes []string, options ...uixt.ActionOption) *StepMobile {
|
||||
action := uixt.MobileAction{
|
||||
Method: uixt.ACTION_TapByCV,
|
||||
Params: uiTypes,
|
||||
Options: uixt.NewActionOptions(options...),
|
||||
}
|
||||
|
||||
s.mobileStep().Actions = append(s.mobileStep().Actions, action)
|
||||
return &StepMobile{step: s.step}
|
||||
}
|
||||
|
||||
// DoubleTapXY double taps the point {X,Y}, X & Y is percentage of coordinates
|
||||
func (s *StepMobile) DoubleTapXY(x, y float64, options ...uixt.ActionOption) *StepMobile {
|
||||
s.mobileStep().Actions = append(s.mobileStep().Actions, uixt.MobileAction{
|
||||
|
||||
Reference in New Issue
Block a user