AWS Device Farm
Cloud service · AWS · Updated

AWS Device Farm

In short

AWS Device Farm is a cloud-based service that allows developers to test and interact with their mobile and web applications on real devices, enabling them to catch issues before launch by providing an extensive range of physical devices for testing.

Cloud Services Hub →

8 key features of AWS Device Farm

AWS Device Farm facilitates cross-platform application testing on a range of real devices and browsers, supports both automated and manual testing, easily integrates with CI/CD pipelines, offers the creation of private device fleets, and provides comprehensive metrics and reports to streamline the testing process.

01
Cross-platform App Testing

AWS Device Farm allows developers to test their web and mobile applications across a wide variety of desktop browsers and real mobile devices without the need for you to own or manage them, ensuring your application functions correctly on the devices your customers use.

02
Remote Access to Real Devices

Provides the ability to interact with real devices in real-time for manual testing purposes. This feature allows developers to swipe, gesture, and interact with devices as if they were holding them, giving an accurate feel of user interaction.

03
Automated Testing

Supports automated testing frameworks such as Appium, XCTest, and Espresso, allowing developers to run their test suites concurrently on multiple devices, which speeds up the testing process and helps in quickly identifying issues or bugs.

04
Continuous Testing Integration

Easily integrates with CI/CD pipelines, enabling developers to automate their testing process as part of their deployment cycle. This integration helps in ensuring that any new code changes do not break existing functionality.

05
Private Device Fleet

Offers the option to set up a dedicated fleet of devices that cater specifically to your testing needs. This private fleet can consist of specific device models required for testing applications, ensuring consistency and availability.

06
Testing Metrics and Reports

Generates detailed reports and logs that include screenshots, videos, and performance data from your test runs, helping developers easily pinpoint issues and improve the quality of their applications.

07
Private Endpoint Access

Device Farm test hosts and devices can securely connect to your VPC to access private endpoints.

08
Rule-Based Device Pool Limits

Device pools can select available devices using rules and cap their number with max_devices to control testing costs. A pool can contain fewer devices than the cap when fewer available devices match its rules.

Where AWS Device Farm is used

AWS Device Farm supports automated and manual testing of mobile and web applications across a diverse array of devices, enables real-world scenario simulations, integrates with CI/CD pipelines for automated testing, and offers scalability in testing efforts.

  1. 01
    App Functional Testing Across Devices

    AWS Device Farm allows developers to test their mobile and web applications across hundreds of different devices and operating systems. This ensures the app works seamlessly in diverse user environments, identifying issues like layout problems or crashes on specific device models or OS versions.

  2. 02
    Automated Testing at Scale

    Leverage AWS Device Farm to execute automated tests using frameworks like Appium, XCTest, or Espresso. This helps in running simultaneous tests at scale, reducing the time required for comprehensive testing phases and speeding up the feedback loop for development.

  3. 03
    Real-world Simulation

    Developers can simulate network connection types and conditions using curated or custom network profiles that control throughput, jitter, and loss. Network shaping applies to device Wi-Fi traffic, and test scripts can change network parameters dynamically.

  4. 04
    Continuous Integration and Delivery (CI/CD) Pipeline Integration

    Integrate AWS Device Farm with your CI/CD pipeline to automate testing as part of your application deployment process. This ensures that each build is automatically tested across a wide array of devices, catching issues early and streamlining the release process.

  5. 05
    Remote Access to Devices for Manual Testing

    AWS Device Farm offers remote access to devices for manual testing purposes. This feature is especially useful for developers or QA engineers who need to reproduce specific issues, explore device-specific behaviors, or perform exploratory testing without needing physical access to a variety of devices.

How AWS Device Farm is priced

AWS Device Farm offers a Pay as You Go model for flexible usage and an Unlimited Testing model for extensive testing needs.

Pay as You Go

This model allows users to pay for the actual device minutes used at a rate per minute, providing flexibility and control over testing costs.

Unlimited Testing

This offers unlimited testing for a flat monthly fee, ideal for teams requiring extensive device testing over longer periods.

Private Device Subscriptions

Each private device has a monthly subscription price tiered according to the device's cost, starting at $200 per month.

Desktop Browser Pay as You Go

Desktop browser testing costs $0.005 per browser instance minute, based on the duration of tests on each selected browser instance.

Services AWS Device Farm works with

AWS CodePipelineAWS CodePipeline

AWS CodePipeline is a continuous integration and continuous delivery (CI/CD) service for fast and reliable application and infrastructure updates. Device Farm can be included as a test action in a CodePipeline build to automatically test applications on real devices when code changes are pushed.

AWS CodeBuildAWS CodeBuild

AWS CodeBuild is a fully managed build service that compiles source code, runs tests, and produces software packages. Device Farm can work alongside CodeBuild to execute automated tests on mobile devices or browsers as part of the build process.

AWS CodeCommitAWS CodeCommit

AWS CodeCommit is a secure, scalable, and managed source control service. It integrates with Device Farm to allow users to automatically trigger tests on real devices when changes are detected in the repository.

Amazon EC2Amazon EC2

AWS Device Farm uses managed Amazon EC2 test hosts to execute tests and provide desktop browser testing environments. Device Farm manages this infrastructure, so you do not need to provision or maintain the instances yourself.

Amazon S3Amazon S3

AWS Device Farm stores uploaded applications, test packages, and test results in service-managed Amazon S3 buckets. Test artifacts such as logs and screenshots can be downloaded after a run.

Amazon VPCAmazon VPC

AWS Device Farm can connect test hosts and devices to private endpoints in your Amazon VPC. This lets you test applications against private backend services without exposing those services to the internet.

AWS CloudFormationAWS CloudFormation

AWS Device Farm resources can be provisioned through AWS CloudFormation, including projects, device pools, instance profiles, network profiles, and desktop browser testing projects. Templates let you reproduce testing configurations across environments.

AWS CloudTrailAWS CloudTrail

AWS Device Farm API calls are recorded by AWS CloudTrail. These records let you audit who created a test run, changed a project, or performed other Device Farm operations and when the requests occurred.

AWS Identity and Access Management (IAM)AWS Identity and Access Management (IAM)

AWS Device Farm uses IAM policies to control access to its projects, test runs, remote access sessions, and other resources. Device Farm also uses service-linked roles to manage the network interfaces needed for supported VPC connectivity.

AWS PrivateLinkAWS PrivateLink

AWS Device Farm supports VPC endpoint configurations that connect tests to private services exposed through AWS PrivateLink. This allows test devices to reach a private application backend through a VPC endpoint service.

What is AWS Device Farm

3 min read

AWS Device Farm is an app testing service provided by Amazon Web Services, which enables developers to improve the quality of their web and mobile applications by testing them across an extensive range of desktop browsers and mobile devices. This service facilitates the simulation of real-world scenarios, offering insights into the performance, functionality, and usability of apps, thus enabling developers to identify and rectify issues before their software reaches the end user. 

One of the key features of AWS Device Farm is its immense repository of desktop, iOS, and Android devices, which includes not just the latest models but also older versions, allowing developers to ensure their applications function seamlessly across a vast spectrum of devices and operating systems. This wide device coverage is crucial in today's fragmented device market, ensuring that applications provide a consistent user experience regardless of the user's device. 

Desktop browser testing uses a client-side execution model: Selenium tests run on your own local machine and interact with browsers hosted on Device Farm through the Selenium API.

For workloads requiring exclusive devices, Device Farm also offers a private device lab. It provisions iOS and Android devices with your required configurations and lets you persist settings between sessions without waiting for other customers to finish using the devices.

AWS Device Farm simplifies the testing process by allowing developers to run their tests simultaneously on multiple devices, significantly reducing the time and resources required for testing. This parallel testing feature is particularly beneficial in agile and DevOps environments, where the speed of development and deployment is critical. Developers can upload their application and run their test scripts directly on AWS Device Farm, and then receive detailed reports that include high-level results, logs, videos, and screenshots, which can be instrumental in identifying and fixing issues swiftly. 

Default metered concurrency quotas are five devices for automated tests and two devices for remote access sessions per supported Region. Both quotas are adjustable.

Automated test runs and remote access sessions each have a hard duration limit of 150 minutes.

The maximum uploaded file size is 4 GB, and this quota is not adjustable.

Another compelling aspect of AWS Device Farm is its flexibility. It supports a wide range of testing frameworks and languages, accommodating various testing strategies, whether automated or manual. For automated testing, developers can use popular frameworks such as Appium, Calabash, and Espresso, ensuring a broad compatibility with existing testing suites and methodologies. On the other hand, manual testing allows for interactive sessions with devices, offering a more nuanced understanding of the user experience. 

Appium tests can also run client-side from your local environment through a remote access session.

An automated run that does not use a custom test environment can contain at most 250 individual test cases; exceeding that limit may cause the run to be skipped.

Moreover, AWS Device Farm is not just limited to functional testing; it enables performance testing, allowing developers to gauge their application's behavior under various conditions and load scenarios. This capability is vital for predicting and optimizing application performance, ensuring applications are robust and deliver a smooth user experience. Integrating seamlessly with other AWS services, Device Farm exemplifies cloud-based efficiency, providing scalable, on-demand testing solutions that align with the needs of modern application development. Its pay-as-you-go pricing model further enhances its appeal, offering cost-effectiveness by eliminating the need for significant upfront investments in device inventory and infrastructure. 

In essence, AWS Device Farm offers a comprehensive, flexible, and efficient solution for application testing, catering to the multifaceted needs of today's developers and ensuring that applications meet the highest standards of quality and performance before they reach the consumer.

Concepts related to AWS Device Farm

AWS Device Farm exam questions

Real practice exam questions on AWS Device Farm, with the correct answer and its explanation. Answer them with every option in the exam simulator.

DOP-C02

A company releases a browser-based analytics application through AWS CodePipeline. An AWS CodeBuild action runs a version-controlled Selenium suite that measures the time until an interactive dashboard is ready and verifies that its charts contain the expected data. The company wants to run the suite concurrently on managed Chrome and Firefox browsers without installing browsers in CodeBuild or maintaining browser hosts.

Each execution must test the candidate deployment with a fixed dataset and browser configuration, compare dashboard timings with an approved baseline, and block promotion if functional checks fail or timings exceed the permitted regression. Pipeline executions can occur several days apart.

Which solution meets these requirements?

Show answerCORRECT ANSWER

Create an AWS Device Farm desktop browser testing project. During each CodeBuild execution, call CreateTestGridUrl and use the returned URL to establish Selenium RemoteWebDriver sessions before the URL expires. Run the suite against the candidate deployment, compare the measured timings with the baseline, and exit nonzero for functional failures, performance regressions, or incomplete tests.

Device Farm desktop browser testing provides managed browsers through Selenium RemoteWebDriver. CreateTestGridUrl generates a time-limited endpoint for establishing sessions, so obtaining a fresh URL for each execution avoids failures caused by an expired endpoint. The test harness can enforce both functional assertions and application-specific timing thresholds, while a nonzero exit status fails the CodeBuild pipeline action.

Practice AWS Device Farm in a full exam

Questions on AWS Device Farm in each practice exam, with every answer option and an explanation for each:

Start a free practice exam

Learn AWS Device Farm in lessons

1 short lesson on AWS Device Farm in 1 certification course.

Open the lessons

AWS architecture icons are the property of Amazon Web Services. BlowStack is not affiliated with or endorsed by AWS.