Browse Source

back to trying to run ARM

Daniel Zlotin 7 years ago
parent
commit
a71a4aa327
4 changed files with 16 additions and 12 deletions
  1. 6
    0
      .travis.yml
  2. 2
    2
      scripts/env/installAndroidSDK.sh
  3. 4
    6
      scripts/test.e2e.android.js
  4. 4
    4
      scripts/travis.sh

+ 6
- 0
.travis.yml View File

13
   - master
13
   - master
14
   - v2
14
   - v2
15
 
15
 
16
+before_cache:
17
+  - rm -f  $HOME/.gradle/caches/modules-2/modules-2.lock
18
+  - rm -fr $HOME/.gradle/caches/*/plugin-resolution/
16
 cache:
19
 cache:
17
   directories:
20
   directories:
18
     - $YARN_CACHE
21
     - $YARN_CACHE
19
     - $HOME/.m2
22
     - $HOME/.m2
23
+    - $HOME/.gradle/caches/
24
+    - $HOME/.gradle/wrapper/
25
+    - $HOME/.android/build-cache
20
 
26
 
21
 install:
27
 install:
22
         # node:
28
         # node:

+ 2
- 2
scripts/env/installAndroidSDK.sh View File

18
 mkdir -p "${ANDROID_HOME}"/licenses
18
 mkdir -p "${ANDROID_HOME}"/licenses
19
 cp "$scriptdir/android-sdk-licenses/"* "${ANDROID_HOME}"/licenses
19
 cp "$scriptdir/android-sdk-licenses/"* "${ANDROID_HOME}"/licenses
20
 
20
 
21
-package="system-images;android-24;default;x86"
21
+package="system-images;android-24;default;armeabi_v7a"
22
 echo "Downloading emulator"
22
 echo "Downloading emulator"
23
 sdkmanager "emulator"
23
 sdkmanager "emulator"
24
 echo "Downloading $package"
24
 echo "Downloading $package"
25
 sdkmanager "${package}"
25
 sdkmanager "${package}"
26
 echo "Creating avd"
26
 echo "Creating avd"
27
-echo no | avdmanager create avd --force --name "pixel" --abi "default/x86" --package "${package}" --device "pixel"
27
+echo no | avdmanager create avd --force --name "pixel" --abi "default/armeabi_v7a" --package "${package}" --device "pixel"
28
 sleep 2
28
 sleep 2
29
 avdmanager list avd
29
 avdmanager list avd

+ 4
- 6
scripts/test.e2e.android.js View File

9
 function run() {
9
 function run() {
10
   if (process.env.CI) {
10
   if (process.env.CI) {
11
     try {
11
     try {
12
-      // console.log(`android e2e disabled on CI for now`);
13
       launchEmulator();
12
       launchEmulator();
14
       runTests();
13
       runTests();
15
     } finally {
14
     } finally {
21
 }
20
 }
22
 
21
 
23
 function runTests() {
22
 function runTests() {
24
-  console.log('all OK');
25
-  // exec.execSync(`yarn run uninstall-android`);
26
-  // exec.execSync(`yarn run install-android ${release ? '-- release' : ''}`);
27
-  // exec.execSync(`cd AndroidE2E && ./gradlew connectedDebugAndroidTest`);
23
+  exec.execSync(`yarn run uninstall-android`);
24
+  exec.execSync(`yarn run install-android ${release ? '-- release' : ''}`);
25
+  exec.execSync(`cd AndroidE2E && ./gradlew connectedDebugAndroidTest`);
28
 }
26
 }
29
 
27
 
30
 function launchEmulator() {
28
 function launchEmulator() {
31
   console.log(`Launching Android Emulator`);
29
   console.log(`Launching Android Emulator`);
32
-  exec.execSync(`cd $ANDROID_HOME/tools && ./emulator -skin 1080x1920 -gpu host -no-audio @pixel`);
30
+  exec.execSync(`cd $ANDROID_HOME/tools && ./emulator -skin 1080x1920 -no-audio @pixel`);
33
   exec.execSync(`./scripts/waitForAndroidEmulator.sh`);
31
   exec.execSync(`./scripts/waitForAndroidEmulator.sh`);
34
 }
32
 }
35
 
33
 

+ 4
- 4
scripts/travis.sh View File

21
 
21
 
22
 run_f "yarn install"
22
 run_f "yarn install"
23
 run_f "yarn run clean"
23
 run_f "yarn run clean"
24
-# run_f "yarn run test-js"
24
+run_f "yarn run test-js"
25
 run_f "yarn run test-unit-android -- release"
25
 run_f "yarn run test-unit-android -- release"
26
-# run_f "yarn run test-unit-ios -- release"
26
+run_f "yarn run test-unit-ios -- release"
27
 run_f "yarn run test-e2e-android -- release"
27
 run_f "yarn run test-e2e-android -- release"
28
-# run_f "yarn run test-e2e-ios -- release"
29
-# run_f "yarn run release"
28
+run_f "yarn run test-e2e-ios -- release"
29
+run_f "yarn run release"