refactor ios: replace gidevice with go-ios

This commit is contained in:
lilong.129
2024-11-23 14:12:07 +08:00
parent 8aac2181be
commit ef37d88e0b
118 changed files with 2202 additions and 11764 deletions

View File

@@ -262,7 +262,7 @@ func TestDriver_Drag(t *testing.T) {
}
time.Sleep(time.Millisecond * 200)
err = driver.DragFloat(400, 501.5, 400, 261.5)
err = driver.Drag(400, 501.5, 400, 261.5)
if err != nil {
t.Fatal(err)
}
@@ -502,3 +502,21 @@ func TestTapTexts(t *testing.T) {
t.Fatal(err)
}
}
func TestRecordVideo(t *testing.T) {
setupAndroidAdbDriver(t)
path, err := driverExt.Driver.(*adbDriver).RecordScreen("", 5*time.Second)
if err != nil {
t.Fatal(err)
}
println(path)
}
func Test_Android_Backspace(t *testing.T) {
setupAndroidAdbDriver(t)
err := driverExt.Driver.Backspace(1)
if err != nil {
t.Fatal(err)
}
}