Integration tests for Session app on iOS and Android using Playwright and Appium.
-
Install dependencies:
nvm use npm install -g yarn yarn install --immutable
-
Setup environment:
cp .env.sample .env # Edit .env with your specific paths - see Environment Configuration below
-
Run tests locally:
yarn start-server # Starts Appium server yarn test # Run all tests yarn test-android # Android tests only yarn test-ios # iOS tests only yarn test-one 'Test name' # Run specific test (both platforms) yarn test-one 'Test name @android' # Run specific test on one platform
Note: The tests use devices with specific resolutions for visual regression testing - ensure you have these available (see below).
Prerequisites: Android Studio installed with SDK tools
- Create Pixel 6 emulators via AVD Manager (minimum 3 emulators - tests require up to 3 devices simultaneously)
- Recommended system image is Android API 34 with Google Play services
- Download Session binaries from the build repository
- Choose the appropriate binary based on your network access:
- QA: Works on general networks
- AutomaticQA: Requires local devnet access
- Choose the appropriate binary based on your network access:
- Start emulators manually - they need to be running before tests start (Appium won't launch them automatically)
Prerequisites: Xcode installed with minimum 3 iPhone 16 Pro Max simulators. The recommended Simulator runtime is iOS 18.3 or higher
- Download Session binaries from the build repository
- Extract .app file for Appium testing:
- If using pre-built binaries from the CI, use the .app directly
- Copy Session.app to an easily accessible location
- Get iOS simulator UUIDs:
xcrun simctl list devices | grep "iPhone 16 Pro Max"
- Update environment configuration with path to Session.app and device UUIDs
Copy .env.sample
to .env
and configure the following:
Required paths:
ANDROID_SDK_ROOT=/path/to/Android/Sdk # SDK tools auto-discovered from here
ANDROID_APK=/path/to/session-android.apk # Android APK for testing
IOS_APP_PATH_PREFIX=/path/to/Session.app # iOS app for testing
Test configuration:
PLAYWRIGHT_RETRIES_COUNT=0 # Test retry attempts
PLAYWRIGHT_WORKERS_COUNT=1 # Parallel test workers
CI=0 # Set to 1 to simulate CI (mostly for Allure reporting)
ALLURE_ENABLED='false' # Set to 'true' to generate Allure reports (in conjunction with CI=1)
Having multiple adb installations can cause test instability. On Linux, ensure only the SDK version is available:
sudo apt remove adb android-tools-adb
which adb # Should return nothing
Tests are tagged with device requirements and risk levels:
@N-devices
- N-device tests (N = 1 || 2 || 3)@high-risk
,@medium-risk
,@low-risk
- Risk-based test categorization@android
,@ios
- Platform-specific tests