Dataford
Interview QuestionsInterview GuidesExperiencesMock InterviewsPricing
Get started
Android Architecture and Appium Setup
00:00
5 left

Android Architecture and Appium Setup

MediumPython

Problem

Tell me about your approach to Android architecture and how you set up Appium to automate a mobile app.

For the hands-on portion, implement build_appium_capabilities to convert Android test settings into canonical W3C Appium capabilities. Preserve unrelated W3C capabilities, apply required defaults, and return {} when required settings are missing.

Input and Output

The function receives one dictionary and returns a dictionary containing platformName plus appium:-prefixed Android capabilities.

Constraints

  • capabilities is a dictionary with string keys.
  • platformName, device name, and app path are required.
  • Device, app, and driver settings may use either their short name or an appium: prefix.
  • If both forms exist, the prefixed form takes precedence.
  • Unrelated W3C capabilities must be preserved.
  • The returned dictionary must use canonical appium: prefixes for Appium-specific settings.

Function Signature

def build_appium_capabilities(capabilities):
Interviewer

Your question is Android Architecture and Appium Setup. Start with the requirements in the Question tab.

Run and submit as often as you like. When you're ready, talk me through your approach or go straight to the code.

You need to log in / sign up to run or submit.
CodePython 3
You need to log in / sign up to run or submit.Ln 2
Run your code to see test output here.