mirror of
https://github.com/facebook/react-native.git
synced 2026-11-18 20:19:07 +00:00
Run Android E2E with ARM64 APKs (#58092)
Summary: Build only the `arm64-v8a` Android ABI for dry-run CI artifacts and run the ARM64 RNTester and template-app APKs on an API 35 `google_apis` x86_64 emulator using the system images built-in NDK translation support. This also makes the Maestro emulator API level and target configurable, logs the device ABI/native-bridge configuration, and updates local RNTester artifact selection to use the ARM64 split. Release and nightly publication builds continue to build all supported Android ABIs. ## Changelog: [INTERNAL] [CHANGED] - Run Android E2E tests with ARM64 APKs through NDK translation. Pull Request resolved: https://github.com/react/react-native/pull/58092 Test Plan: - `node --check .github/workflow-scripts/maestro-android.js` — passed. - `node --check scripts/release-testing/test-release-local.js` — passed. - Parsed all modified YAML files with the `yaml` Node package — passed. - `./node_modules/.bin/prettier --check <modified files>` — passed. - `git diff --check HEAD~3..HEAD` — passed. - `actionlint` reported only existing repository metadata warnings for the custom `4-core-ubuntu` label and the missing description in the local `yarn-install` action. - `yarn test .github/workflow-scripts/__tests__/maestro-android-test.js --runInBand` could not start because the local dependency tree is missing `flow-parser`; restoring dependencies was blocked by HTTP 503 responses from the npm registry. - The draft CI run should validate ARM64 APK installation, Hermes startup, and the complete Maestro suites through `libndk_translation.so`. Reviewed By: Abbondanzo Differential Revision: D117195078 Pulled By: cortinico fbshipit-source-id: a78f2127f04e80c3b5ca4c95d2024dffb92ff122
This commit is contained in:
1 parent
3f9cc72309
commit
25ebffd1f7
7 files changed
+47
-17
No files matched your search
@@ -155,18 +155,15 @@ async function testRNTesterAndroid(
|
||||
if (ciArtifacts != null) {
|
||||
const downloadPath = path.join(ciArtifacts.baseTmpPath(), 'rntester.zip');
|
||||
|
||||
const emulatorArch = exec('adb shell getprop ro.product.cpu.abi').trim();
|
||||
|
||||
// Github Actions zips all the APKs in a single archive
|
||||
console.info('Start Downloading APK');
|
||||
const rntesterAPKURL =
|
||||
await ciArtifacts.artifactURLForRNTesterAPK(emulatorArch);
|
||||
const rntesterAPKURL = await ciArtifacts.artifactURLForRNTesterAPK();
|
||||
|
||||
ciArtifacts.downloadArtifact(rntesterAPKURL, downloadPath);
|
||||
const unzipFolder = path.join(ciArtifacts.baseTmpPath(), 'rntester-apks');
|
||||
exec(`rm -rf ${unzipFolder}`);
|
||||
exec(`unzip ${downloadPath} -d ${unzipFolder}`);
|
||||
let apkPath = path.join(unzipFolder, `app-${emulatorArch}-debug.apk`);
|
||||
const apkPath = path.join(unzipFolder, 'app-arm64-v8a-debug.apk');
|
||||
|
||||
exec(`adb install ${apkPath}`);
|
||||
} else {
|
||||
|
||||
@@ -203,9 +203,7 @@ function downloadArtifact(
|
||||
exec(command, {stdio: 'inherit'});
|
||||
}
|
||||
|
||||
async function artifactURLForRNTesterAPK(
|
||||
emulatorArch /*: string */,
|
||||
) /*: Promise<string> */ {
|
||||
async function artifactURLForRNTesterAPK() /*: Promise<string> */ {
|
||||
return getArtifactURL('rntester-debug');
|
||||
}
|
||||
|
||||
|
||||
Reference in new issue
Block a user