浏览代码

Fixed JavaScript Kokoro tests by installing NodeJS. (#7504)

* Fix JavaScript tests.

* Added missing popd.

* Added missing 'export' for $PATH.

* Fixed path to include 'bin'.
Joshua Haberman 5 年之前
父节点
当前提交
79b1c3bac3
共有 1 个文件被更改,包括 7 次插入0 次删除
  1. 7 0
      tests.sh

+ 7 - 0
tests.sh

@@ -446,6 +446,13 @@ build_ruby27() {
 
 build_javascript() {
   internal_build_cpp
+  NODE_VERSION=node-v12.16.3-darwin-x64
+  NODE_TGZ="$NODE_VERSION.tar.gz"
+  pushd /tmp
+  curl -OL https://nodejs.org/dist/v12.16.3/$NODE_TGZ
+  tar zxvf $NODE_TGZ
+  export PATH=$PATH:`pwd`/$NODE_VERSION/bin
+  popd
   cd js && npm install && npm test && cd ..
   cd conformance && make test_nodejs && cd ..
 }