mirror of
https://github.com/httprunner/httprunner.git
synced 2026-07-12 16:01:27 +08:00
feat: check android uiautomator server package installed
This commit is contained in:
@@ -675,7 +675,7 @@ func (d *Device) ListPackages() ([]string, error) {
|
||||
return packages, nil
|
||||
}
|
||||
|
||||
func (d *Device) IsPackagesInstalled(packageName string) bool {
|
||||
func (d *Device) IsPackageInstalled(packageName string) bool {
|
||||
packages, err := d.ListPackages()
|
||||
if err != nil {
|
||||
return false
|
||||
|
||||
@@ -349,7 +349,7 @@ func TestDevice_ListPackages(t *testing.T) {
|
||||
t.Fatal(err)
|
||||
}
|
||||
t.Log(res)
|
||||
installed := dev.IsPackagesInstalled("io.appium.uiautomator2.server")
|
||||
installed := dev.IsPackageInstalled("io.appium.uiautomator2.server")
|
||||
if err != nil {
|
||||
t.Fatal(err)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user