React Native CI/CD Interview Questions
20 questions with detailed answers
Q1. Explain the difference between CI and CD in mobile development.
Answer: CI (Continuous Integration) automatically builds and tests every code change — lint, unit tests, compile. CD (Continuous Delivery/Deployment) extends this to produce signed artifacts and deliver them to testers or stores (TestFlight, Play Internal). Mobile CD often stops at store promotion gates.
Q2. Why can't you build iOS apps on a standard Linux CI runner?
Answer: iOS builds require Xcode and Apple's toolchain, which only run on macOS. You need macOS runners (GitHub Actions macos-*, Codemagic, Bitrise) or a cloud build service like EAS.
Q3. What is the difference between versionName and versionCode on Android?
Answer: versionName is the user-visible version string (e.g. 2.4.0). versionCode is an integer that must monotonically increase with every Play Store upload — stores reject duplicate or lower versionCodes.
Q4. How does Fastlane fit into a React Native CI pipeline?
Answer: Fastlane lanes automate repetitive release tasks: increment build numbers, run gradle/xcodebuild, manage certificates (match), upload to Play Store/TestFlight, and post notifications. CI triggers Fastlane; Fastlane handles mobile-specific release steps.
Q5. What is Detox and when would you use it vs Jest?
Answer: Jest runs unit/integration tests in Node without a device. Detox runs E2E tests on simulators/emulators, tapping real UI elements. Use Jest for logic/components; Detox for critical user flows (login, checkout, navigation).
Q6. Describe a safe branching strategy for React Native releases.
Answer: Use main (production), develop (integration), feature/* (short-lived), release/x.y.z (stabilization), and hotfix/* (urgent fixes from main). Protect main with required checks. Tag every production release. Merge hotfixes back to both main and develop.
Q7. How do you securely manage Android keystore and Play API keys in CI?
Answer: Store keystore as base64 in GitHub Secrets or a secret manager; decode in CI before build. Play service account JSON goes in encrypted secrets, written to a temp file with restricted permissions. Never commit keys. Keep offline keystore backup in team vault.
Q8. What is SEMVER and how does it apply to mobile apps?
Answer: Semantic Versioning: MAJOR.MINOR.PATCH. MAJOR = breaking changes; MINOR = new features; PATCH = bug fixes. Mobile also needs separate monotonic build numbers (versionCode/buildNumber) independent of marketing version.
Q9. Why use Husky and lint-staged together?
Answer: Husky attaches scripts to git hooks (pre-commit). lint-staged runs ESLint/Prettier only on staged files — fast feedback before push, reducing CI failures and keeping feedback loops under 10 seconds.
Q10. What are the steps to set up Play Console API access for automated uploads?
Answer: Create Play Developer account → link GCP project in API access → create service account → grant release permissions in Play Console → download JSON key → store in CI secrets → reference in Fastlane upload_to_play_store json_key parameter.
Q11. Compare GitHub Actions, Bitrise, and Codemagic for React Native.
Answer: GitHub Actions: native to GitHub, flexible YAML, Mac runners for iOS. Bitrise: mobile-first UI, strong RN templates, paid. Codemagic: RN/Flutter focused, simple config, M1 Mac runners. Choice depends on team size, budget, and existing tooling.
Q12. How would you design a PR pipeline vs a release pipeline?
Answer: PR pipeline (fast, <15 min): lint, typecheck, Jest, Android debug/release build. Release pipeline (slower): SEMVER bump, signed builds, Fastlane upload, Discord notify, optional Detox smoke. Nightly: full E2E on Genymotion.
Q13. What is Play App Signing and why does it matter?
Answer: Google manages your app signing key. You sign uploads with an upload key. If upload key is lost, you can reset it. This protects against key loss bricking your app updates and enables Google's optimization features.
Q14. How do Discord webhooks improve mobile release workflows?
Answer: They push build status (success/failure, branch, version) to a team channel in real time. QA knows when TestFlight/Internal builds are ready without monitoring GitHub. Failures get immediate visibility for faster MTTR.
Q15. What is Genymotion SaaS and when would you use it over local emulators?
Answer: Cloud-hosted Android emulators accessible via API/CLI. Use in CI when Linux runners lack KVM or you need consistent device profiles. Connect via adb, run Detox tests, tear down instance. Cost-effective for nightly E2E, not every PR.
Q16. Expo EAS vs bare React Native + Fastlane — when to choose each?
Answer: EAS: faster setup, managed credentials, good for Expo/managed workflow teams. Bare + Fastlane: full native control, custom CI, required for heavy native modules or enterprise DevOps standards. Many teams start Expo, eject when needed.
Q17. What should a mobile PR template include?
Answer: Screenshots/video of UI changes, test plan, version impact (SEMVER bump needed?), migration notes, linked ticket, device/OS tested on, and checklist for native changes (Info.plist, permissions, ProGuard rules).
Q18. How do you handle a bad production release?
Answer: Immediate: halt rollout in Play Console / pause App Store release. Short-term: ship hotfix branch from main with PATCH bump. Long-term: post-mortem, add regression test, improve staging gate. Play supports staged rollouts; use them.
Q19. What are DORA metrics and why should mobile managers track them?
Answer: Deployment frequency, lead time for changes, change failure rate, mean time to recovery. They measure delivery health. Mobile managers use them to justify CI/CD investment and identify bottlenecks (slow signing, manual QA gates, flaky E2E).
Q20. Walk through uploading your first AAB to Internal testing.
Answer: Generate upload keystore → configure signing in gradle → ./gradlew bundleRelease → Play Console → create app → complete store listing → Testing → Internal testing → Create release → upload AAB → add tester emails → Review and roll out → share opt-in link.