bozaigao / detox-react-native

react-native project test buy Detox

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

React Native Demo Project

Environment

Fundamentals

IMPORTANT: Get your environment properly set up, as explained in our contribution guide.

Execution Target

Be sure to set up either an iOS simulator or a proper Android AVD emulator matching the Detox configurations of the project (devices section of the detox.config.js file).

Running this project in Release mode

Step 0: Prebuild

Android

Prebuild Detox as an Android archive (a .aar file), locally:

cd detox
npm run build:android

On success, the result is a set of maven artifacts published in subdirectories under detox/Detox-android/. That includes detox-999.999.999.aar (i.e. Detox' native code packaged with the fake version 999.999.999).

iOS

Install the necessary pods:

cd detox
npm run podInstall:ios

Step 1: Build

Build the demo project using one of the npm scripts.

npm run build:ios-release
-or-
npm run build:android-release

Step 2: Execute Tests

npm run test:ios-release
-or-
npm run test:android-release

Running this project in Debug mode

The project’s tests can also be executed with the app running in debug mode (mainly, with JavaScript code getting bundled on-the-fly using the metro server).

For that, first run the metro server:

npm start

then follow the same instructions specified for Release mode, above, using associated debug scripts instead of the release ones. Namely -

Build:

npm run build:ios-debug
-or-
npm run build:android-debug

Test:

npm run test:ios-debug
-or-
npm run test:android-debug

About

react-native project test buy Detox


Languages

Language:JavaScript 35.4%Language:Java 23.0%Language:Objective-C 20.7%Language:TypeScript 8.3%Language:Starlark 7.5%Language:Ruby 4.4%Language:Shell 0.8%