Move TypeScript, JavaScript tests to CircleCI (#10510)

* move ts, js tests to circleci

* set NODE_ENV

* curl -k

* comment out haskell installation
This commit is contained in:
William Cheng 2021-10-02 15:38:05 +08:00 committed by GitHub
parent 755359c031
commit 026dd8d5f8
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with 8 additions and 31 deletions

View File

@ -21,28 +21,11 @@ cache:
- $HOME/samples/client/petstore/php/OpenAPIToolsClient-php/vendor
- $HOME/samples/client/petstore/ruby/vendor/bundle
- $HOME/samples/client/petstore/python/.venv/
- $HOME/samples/openapi3/client/petstore/typescript/tests/default/node_modules
- $HOME/samples/openapi3/client/petstore/typescript/tests/jquery/node_modules
- $HOME/samples/openapi3/client/petstore/typescript/tests/object_params/node_modules
- $HOME/samples/openapi3/client/petstore/typescript/tests/inversify/node_modules
- $HOME/samples/client/petstore/typescript-node/npm/node_modules
- $HOME/samples/client/petstore/typescript-node/npm/typings/
- $HOME/samples/client/petstore/typescript-fetch/tests/default/node_modules
- $HOME/samples/client/petstore/typescript-fetch/tests/default/typings
- $HOME/samples/client/petstore/typescript-fetch/builds/default/node_modules
- $HOME/samples/client/petstore/typescript-fetch/builds/default/typings
- $HOME/samples/client/petstore/typescript-fetch/builds/es6-target/node_modules
- $HOME/samples/client/petstore/typescript-fetch/builds/es6-target/typings
- $HOME/samples/client/petstore/typescript-fetch/builds/with-npm-version/node_modules
- $HOME/samples/client/petstore/typescript-fetch/npm/with-npm-version/typings
- $HOME/samples/client/petstore/typescript-angular/node_modules
- $HOME/samples/client/petstore/typescript-angular/typings
- $HOME/samples/server/petstore/rust-server/target
- $HOME/perl5
- $HOME/.cargo
- $HOME/.pub-cache
- $HOME/samples/server/petstore/cpp-pistache/pistache
- $HOME/.npm
- $HOME/.rvm/gems/ruby-2.4.1
- $HOME/website/node_modules/
- $HOME/.cache/deno
@ -88,11 +71,6 @@ before_install:
- curl https://sh.rustup.rs -sSf | sh -s -- -y -v
# required when sudo: required for the Ruby petstore tests
- gem install bundler
- nvm install 12.20.0
- nvm use 12.20.0
- npm install -g typescript
- npm install -g npm
- npm config set registry http://registry.npmjs.org/
# set python 3.6.3 as default
- source ~/virtualenv/python3.6/bin/activate
# -- skip bash test to shorten build time

View File

@ -7,6 +7,8 @@ NODE_INDEX=${CIRCLE_NODE_INDEX:-0}
set -e
export NODE_ENV=test
function cleanup {
# Show logs of 'petstore.swagger' container to troubleshoot Unit Test failures, if any.
docker logs petstore.swagger # container name specified in circle.yml
@ -20,15 +22,12 @@ if [ "$NODE_INDEX" = "1" ]; then
mvn --no-snapshot-updates --quiet verify -Psamples.circleci -Dorg.slf4j.simpleLogger.defaultLogLevel=error
echo "show ivy2 cache"
ls -l /home/circleci/.ivy2/cache
elif [ "$NODE_INDEX" = "2" ]; then
echo "Running node $NODE_INDEX to test haskell"
# install haskell
curl -sSL https://get.haskellstack.org/ | sh
stack upgrade
stack --version
#curl -sSLk https://get.haskellstack.org/ | sh
#stack upgrade
#stack --version
# prepare r
sudo sh -c 'echo "deb http://cran.rstudio.com/bin/linux/ubuntu trusty/" >> /etc/apt/sources.list'
gpg --keyserver keyserver.ubuntu.com --recv-key E084DAB9

View File

@ -1193,8 +1193,6 @@
</property>
</activation>
<modules>
<module>samples/client/petstore/typescript-axios/builds/with-npm-version</module>
<module>samples/client/petstore/typescript-axios/tests/default</module>
<!-- TODO: move to github action or circleci
<module>samples/client/petstore/crystal</module>-->
<!-- servers -->
@ -1222,7 +1220,6 @@
<!-- commented out due to php ^7.3 || ^8.0 not in travis
<module>samples/client/petstore/php/OpenAPIClient-php</module> -->
<!--<module>samples/client/petstore/javascript-apollo</module>-->
<module>samples/client/petstore/javascript-flowtyped</module>
<module>samples/client/petstore/python-legacy</module>
<module>samples/client/petstore/python-asyncio</module>
<module>samples/client/petstore/python-tornado</module>
@ -1359,6 +1356,7 @@
<!-- test non-java projects -->
<module>samples/client/petstore/go</module>
<module>samples/openapi3/client/petstore/go</module>
<module>samples/client/petstore/javascript-flowtyped</module>
<module>samples/client/petstore/javascript-es6</module>
<module>samples/client/petstore/javascript-promise-es6</module>
<module>samples/server/petstore/go-api-server</module>
@ -1386,6 +1384,8 @@
<module>samples/client/petstore/typescript-fetch/tests/default</module>
<module>samples/client/petstore/typescript-node/npm</module>
<module>samples/client/petstore/typescript-rxjs/builds/with-npm-version</module>
<module>samples/client/petstore/typescript-axios/builds/with-npm-version</module>
<module>samples/client/petstore/typescript-axios/tests/default</module>
</modules>
</profile>
<!-- test with JDK9 in Shippable CI -->