refactor: merge Tap and TapFloat

This commit is contained in:
lilong.129
2024-11-23 22:10:49 +08:00
parent 89a08f61ec
commit ad796590b5
10 changed files with 12 additions and 37 deletions
+1 -9
View File
@@ -219,7 +219,7 @@ func (s *stubIOSDriver) Orientation() (orientation Orientation, err error) {
}
// Tap Sends a tap event at the coordinate.
func (s *stubIOSDriver) Tap(x, y int, options ...ActionOption) error {
func (s *stubIOSDriver) Tap(x, y float64, options ...ActionOption) error {
err := s.setUpWda()
if err != nil {
return err
@@ -227,14 +227,6 @@ func (s *stubIOSDriver) Tap(x, y int, options ...ActionOption) error {
return s.wdaDriver.Tap(x, y, options...)
}
func (s *stubIOSDriver) TapFloat(x, y float64, options ...ActionOption) error {
err := s.setUpWda()
if err != nil {
return err
}
return s.wdaDriver.TapFloat(x, y, options...)
}
// DoubleTap Sends a double tap event at the coordinate.
func (s *stubIOSDriver) DoubleTap(x, y float64, options ...ActionOption) error {
err := s.setUpWda()