@@ -158,7 +158,7 @@ jobs:
158
158
name : Install Detox Utils
159
159
command : brew tap wix/brew && brew install applesimutils
160
160
- run :
161
- name : Install node_modules
161
+ name : Install Node Packages
162
162
command : yarn
163
163
- run :
164
164
name : Fetch CocoaPods Specs
@@ -173,6 +173,65 @@ jobs:
173
173
name : Detox - Run E2E Tests
174
174
command : detox test --configuration ios.sim.release --cleanup
175
175
176
+ e2e_android :
177
+ macos :
178
+ xcode : " 10.2.0"
179
+ working_directory : ~/project/InstabugSample
180
+ steps :
181
+ - checkout :
182
+ path : ~/project
183
+ - run :
184
+ name : Install Android SDK
185
+ command : |
186
+ HOMEBREW_NO_AUTO_UPDATE=1 brew tap homebrew/cask
187
+ HOMEBREW_NO_AUTO_UPDATE=1 brew cask install android-sdk
188
+ - run :
189
+ name : Accept Android SDK Licenses
190
+ command : (yes | sdkmanager --licenses) || true
191
+ - run :
192
+ name : Setup Android Environment Variables
193
+ command : |
194
+ echo 'export JAVA_HOME=`/usr/libexec/java_home -v 1.8`' >> $BASH_ENV
195
+ echo 'export ANDROID_HOME=/usr/local/share/android-sdk' >> $BASH_ENV
196
+ echo 'export ANDROID_SDK_ROOT=/usr/local/share/android-sdk' >> $BASH_ENV
197
+ echo 'export PATH=$PATH:$ANDROID_HOME/tools:$ANDROID_HOME/platform-tools' >> $BASH_ENV
198
+ - run :
199
+ name : SDK Manager - Download Emulator Image
200
+ command : (yes | sdkmanager "platform-tools" "platforms;android-27" "extras;intel;Hardware_Accelerated_Execution_Manager" "build-tools;27.0.3" "system-images;android-27;google_apis;x86" "emulator" --verbose) || true
201
+ - run :
202
+ name : AVD Manager - Setup Emulator
203
+ command : avdmanager create avd -n Nexus_6P_API_27 -k "system-images;android-27;google_apis;x86" -g google_apis -d "Nexus 6P"
204
+ - run :
205
+ name : Run Emulator in background
206
+ command : /usr/local/share/android-sdk/emulator/emulator @Nexus_6P_API_27 -noaudio -no-boot-anim -no-window
207
+ background : true
208
+ - run :
209
+ name : Install Node Packages
210
+ command : sudo yarn
211
+ - run :
212
+ name : Generate Android Keystore
213
+ command : cd android/app && keytool -genkey -v -keystore debug.keystore -storepass android -alias androiddebugkey -keypass android -keyalg RSA -keysize 2048 -validity 10000 -dname "CN=AA, OU=AA, O=AA, L=AA, S=AA, C=EG"
214
+ - run :
215
+ name : Make gradlew Executable
216
+ command : cd android && chmod +x ./gradlew
217
+ - run :
218
+ name : Download Android Dependencies
219
+ command : cd android && ./gradlew androidDependencies
220
+ - run :
221
+ name : Install Detox CLI
222
+ command : sudo npm install -g detox-cli
223
+ - run :
224
+ name : Detox - Build Release App
225
+ command : |
226
+ sudo chmod -R 777 /Users/distiller/project/InstabugSample/node_modules/instabug-reactnative
227
+ detox build --configuration android.emu.release
228
+ - run :
229
+ name : Detox - Run E2E Tests
230
+ command : |
231
+ sudo chmod -R 777 /Users/distiller/Library/Detox
232
+ detox test --configuration android.emu.release --cleanup
233
+
234
+
176
235
publish :
177
236
macos :
178
237
xcode : " 10.1.0"
@@ -192,12 +251,16 @@ workflows:
192
251
- test_sample
193
252
- test_android
194
253
- test_ios
254
+ - e2e_ios
255
+ - e2e_android
195
256
- hold :
196
257
requires :
197
258
- test_module
198
259
- test_sample
199
260
- test_android
200
261
- test_ios
262
+ - e2e_ios
263
+ - e2e_android
201
264
type : approval
202
265
filters :
203
266
branches :
0 commit comments