You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@weex.apache.org by so...@apache.org on 2017/04/12 08:05:52 UTC

[3/6] incubator-weex git commit: * [test] fix CI script

* [test] fix CI script


Project: http://git-wip-us.apache.org/repos/asf/incubator-weex/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-weex/commit/076d11bb
Tree: http://git-wip-us.apache.org/repos/asf/incubator-weex/tree/076d11bb
Diff: http://git-wip-us.apache.org/repos/asf/incubator-weex/diff/076d11bb

Branch: refs/heads/0.12-dev
Commit: 076d11bbc78f0052b3cd60d21e7af425a96e82dd
Parents: 64b0857
Author: sospartan <so...@apache.org>
Authored: Wed Apr 12 15:54:25 2017 +0800
Committer: sospartan <so...@apache.org>
Committed: Wed Apr 12 15:54:25 2017 +0800

----------------------------------------------------------------------
 dangerfile.js    | 9 +++++++++
 test/ci-funcs.sh | 1 +
 2 files changed, 10 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-weex/blob/076d11bb/dangerfile.js
----------------------------------------------------------------------
diff --git a/dangerfile.js b/dangerfile.js
index b206e6e..35eb696 100644
--- a/dangerfile.js
+++ b/dangerfile.js
@@ -144,8 +144,17 @@ const copyright_header_components = [
   'with the License\\.  You may obtain a copy of the License at'
 ];
 
+//path prefix
+const ignoreCopyrightVerifyPath = [
+  'test'
+]
 
 codefiles.forEach(filepath => {
+  for(var i=ignoreCopyrightVerifyPath.length-1;i>=0;i--){
+    if(filepath.startsWith(ignoreCopyrightVerifyPath[i])){
+      return
+    }
+  }
   const content = fs.readFileSync(filepath).toString();
   for (const line of copyright_header_components) {
     if (!content.match(new RegExp(line))) {

http://git-wip-us.apache.org/repos/asf/incubator-weex/blob/076d11bb/test/ci-funcs.sh
----------------------------------------------------------------------
diff --git a/test/ci-funcs.sh b/test/ci-funcs.sh
index c6d0fd6..8db51f6 100644
--- a/test/ci-funcs.sh
+++ b/test/ci-funcs.sh
@@ -98,6 +98,7 @@ function test_cpt {
     
     if [ $target = $target_android ]; then
         ./test/serve.sh 2&>1 > /dev/null &
+        set -eu
         # export ANDROID_HOME=/usr/local/opt/android-sdk
         cd android && ./run-ci.sh && cd $TRAVIS_BUILD_DIR
         waitForEmulator