简体   繁体   中英

Appium automation for iOS Native device features

I am using Appium for mobile native app automation on real devices in Android (4.4x) and iOS (9x). Some of the Test Cases include following operations to be automated:

  • Killing the app under test
  • Enable / Disable Location services
  • Restart Device
  • Lock / Unlock Device
  • Pushing the app in the background
  • Simulating home button

In Android, using adb commands we are able to automate the above scenarios.But in iOS we are stuck and not able to proceed.

The major reason that why we are not able to automate the above operations in iOS is because

  • Appropriate Appium commands are not working
  • No alternative such as adb available in iOS
  • Objects not accessible which can perform these operations

Appreciate your help

Ashish - The test cases you are looking for cannot be automated for iOS. This is mainly because of limitations created by Apple. Basically, all that Apple allows to do is automate your app, and your app operates in a sandbox. If you want to access system lever alerts or apps, you cannot automate that.

Appium is a good tool, but it's just a wrapper on Apple's instruments. If you are trying to get better control of your automation, we recommend using Apple's Instruments scripts or XCTest. This will definitely give you better control. If you have any more questions you can send us an email from our website and we can assist you.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM