-
Notifications
You must be signed in to change notification settings - Fork 4.3k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
E2E Tests - Organize test device configuration (#55701)
* Adds Device config JSON file for E2E testing * Update build_e2e_ios_app script to use device-config.json * Update E2E capabilities config to use device-config.json * Move WDA build script to its own file and updates it to use device-config.json * Update device config with SauceLabs/Buildkite specific config * Update packages/react-native-editor/__device-tests__/helpers/caps.js Co-authored-by: David Calhoun <[email protected]> --------- Co-authored-by: David Calhoun <[email protected]>
- Loading branch information
Showing
5 changed files
with
69 additions
and
10 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
29 changes: 29 additions & 0 deletions
29
packages/react-native-editor/__device-tests__/helpers/device-config.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
{ | ||
"ios": { | ||
"local": { | ||
"deviceName": "iPhone 14", | ||
"deviceTabletName": "iPad (10th generation)", | ||
"platformVersion": "16.2" | ||
}, | ||
"saucelabs": { | ||
"deviceName": "iPhone 14 Simulator", | ||
"deviceTabletName": "iPad (10th generation) Simulator" | ||
}, | ||
"buildkite": { | ||
"platformVersion": "16.4" | ||
}, | ||
"pixelRatio": { | ||
"iPhone": 3, | ||
"iPad": 2 | ||
} | ||
}, | ||
"android": { | ||
"local": { | ||
"deviceName": "Pixel_3_XL_API_30", | ||
"platformVersion": "11.0" | ||
}, | ||
"saucelabs": { | ||
"deviceName": "Google Pixel 3 XL GoogleAPI Emulator" | ||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
#!/bin/bash -eu | ||
|
||
set -o pipefail | ||
|
||
# Load configurations from JSON file | ||
CONFIG_FILE="$(pwd)/__device-tests__/helpers/device-config.json" | ||
IOS_DEVICE_NAME=$(jq -r '.ios.local.deviceName' "$CONFIG_FILE") | ||
IOS_PLATFORM_VERSION=$(jq -r '.ios.local.platformVersion' "$CONFIG_FILE") | ||
|
||
xcodebuild -project ~/.appium/node_modules/appium-xcuitest-driver/node_modules/appium-webdriveragent/WebDriverAgent.xcodeproj -scheme WebDriverAgentRunner -destination "platform=iOS Simulator,name=$IOS_DEVICE_NAME,OS=$IOS_PLATFORM_VERSION" -derivedDataPath ios/build/WDA |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters