Skip to main content
End-to-end (E2E) testing validates complete user workflows across your app. This guide covers popular E2E frameworks and best practices for Expo apps.

Overview

E2E tests run on real devices or simulators, simulating user interactions:
FrameworkEase of SetupBest ForSupported Platforms
MaestroEasyQuick tests, visual validationiOS, Android
DetoxModerateReact Native apps, complex flowsiOS, Android
AppiumComplexCross-platform, existing infrastructureiOS, Android, Web

Maestro

Maestro is a simple, powerful E2E testing framework ideal for Expo apps.

Installation

Writing Tests

1

Create test file

e2e/login.yaml
2

Run test

Maestro Commands

Input

Assertions

Waiting

Advanced Features

Environment Variables

Screenshots

JavaScript Functions

scripts/login.js

Maestro Studio

Interactive test creation:

Detox

Gray-box testing framework synchronized with React Native.

Setup

1

Install Detox

2

Configure Detox

.detoxrc.js
3

Create test

e2e/login.test.ts
4

Run tests

Detox API

Matchers

Actions

Assertions

Appium

Cross-platform testing with WebDriver protocol.

Setup

Writing Tests

e2e/login.test.ts

Test Structure

Page Object Pattern

e2e/pages/LoginPage.ts
e2e/tests/login.test.ts

CI/CD Integration

GitHub Actions (Maestro)

.github/workflows/e2e.yml

EAS Build with E2E Tests

eas.json

Best Practices

1. Use Accessibility IDs

2. Wait for Elements

3. Independent Tests

4. Test Critical Paths

Focus on user-critical workflows:
  • Authentication
  • Core features
  • Purchase flows
  • Data submission

Next Steps

Unit Testing

Complement E2E with unit tests

Testing Router

Test Expo Router navigation

Debugging

Debug test failures

CI/CD

Automate E2E tests