Browse Source

clean up ci

Daniel Zlotin 8 years ago
parent
commit
b7e805a950
2 changed files with 11 additions and 1 deletions
  1. 5
    1
      playground/scripts/e2e.ios.js
  2. 6
    0
      scripts/travis.sh

+ 5
- 1
playground/scripts/e2e.ios.js View File

40
   }
40
   }
41
 }
41
 }
42
 
42
 
43
-function e2e() {
43
+function e2e() { //eslint-disable-line
44
   try {
44
   try {
45
     shellUtils.exec.execSync(`echo 'travis_fold:start:detox-ios'`);
45
     shellUtils.exec.execSync(`echo 'travis_fold:start:detox-ios'`);
46
     shellUtils.exec.execSyncSilent(`watchman watch-del-all || true`);
46
     shellUtils.exec.execSyncSilent(`watchman watch-del-all || true`);
57
   } finally {
57
   } finally {
58
     shellUtils.exec.execSync(`./scripts/detoxDebugFix.rb`);
58
     shellUtils.exec.execSync(`./scripts/detoxDebugFix.rb`);
59
     shellUtils.exec.kill(`detox-server`);
59
     shellUtils.exec.kill(`detox-server`);
60
+    if (process.env.CI) {
61
+      shellUtils.exec.kill(`Simulator`);
62
+      shellUtils.exec.kill(`CoreSimulator`);
63
+    }
60
     shellUtils.exec.execSync(`cat ./detox-server.log`);
64
     shellUtils.exec.execSync(`cat ./detox-server.log`);
61
     shellUtils.exec.execSync(`rm -f ./detox-server.log`);
65
     shellUtils.exec.execSync(`rm -f ./detox-server.log`);
62
     shellUtils.exec.execSync(`sleep 5`);
66
     shellUtils.exec.execSync(`sleep 5`);

+ 6
- 0
scripts/travis.sh View File

1
 #!/bin/bash -e
1
 #!/bin/bash -e
2
 
2
 
3
+color='\033[1;36m'
4
+nocolor='\033[0m'
5
+
3
 run_f () {
6
 run_f () {
4
   cmd="${1}"
7
   cmd="${1}"
5
   name=${cmd//[ ]/_}
8
   name=${cmd//[ ]/_}
6
 
9
 
7
   echo "travis_fold:start:$name"
10
   echo "travis_fold:start:$name"
11
+  echo -e "${color}\t $cmd \t${nocolor}"
12
+
8
   ($cmd)
13
   ($cmd)
14
+
9
   echo "travis_fold:end:$name"
15
   echo "travis_fold:end:$name"
10
 }
16
 }
11
 
17