rebalance circleci tests

This commit is contained in:
WILLIAM CHENG 2021-10-29 09:40:26 +08:00
parent 90176c8a2e
commit ff80c4ea83
3 changed files with 57 additions and 60 deletions

View File

@ -42,24 +42,6 @@ jobs:
command: |-
printf '127.0.0.1 petstore.swagger.io
' | sudo tee -a /etc/hosts
# Dependencies
# Install latest stable node for angular 6
- run:
name: Install node@stable (for angular 6)
command: |
set +e
curl -o- https://raw.githubusercontent.com/creationix/nvm/v0.33.11/install.sh | bash
export NVM_DIR="/opt/circleci/.nvm"
[ -s "$NVM_DIR/nvm.sh" ] && \. "$NVM_DIR/nvm.sh"
#nvm install stable
# install v16 instead of the latest stable version
nvm install 16
nvm alias default 16
# Each step uses the same `$BASH_ENV`, so need to modify it
echo 'export NVM_DIR="/opt/circleci/.nvm"' >> $BASH_ENV
echo "[ -s \"$NVM_DIR/nvm.sh\" ] && . \"$NVM_DIR/nvm.sh\"" >> $BASH_ENV
- run: node --version
# - run: docker pull openapitools/openapi-petstore
# - run: docker run -d -e OPENAPI_BASE_PATH=/v3 -e DISABLE_API_KEY=1 -e DISABLE_OAUTH=1 -p 80:8080 openapitools/openapi-petstore
- run: docker pull swaggerapi/petstore

View File

@ -40,6 +40,13 @@ elif [ "$NODE_INDEX" = "2" ]; then
sudo apt-get -y build-dep libcurl4-gnutls-dev
sudo apt-get -y install libcurl4-gnutls-dev
# Install golang version 1.14
go version
sudo mkdir /usr/local/go1.14
wget -c https://dl.google.com/go/go1.14.linux-amd64.tar.gz -O - | sudo tar -xz -C /usr/local/go1.14
export PATH="/usr/local/go1.14/go/bin:$PATH"
go version
# run integration tests
mvn --no-snapshot-updates --quiet verify -Psamples.misc -Dorg.slf4j.simpleLogger.defaultLogLevel=error
elif [ "$NODE_INDEX" = "3" ]; then
@ -55,6 +62,21 @@ elif [ "$NODE_INDEX" = "3" ]; then
pyenv global 3.6.3
python3 --version
# Install node@stable (for angular 6)
set +e
curl -o- https://raw.githubusercontent.com/creationix/nvm/v0.33.11/install.sh | bash
export NVM_DIR="/opt/circleci/.nvm"
[ -s "$NVM_DIR/nvm.sh" ] && \. "$NVM_DIR/nvm.sh"
#nvm install stable
# install v16 instead of the latest stable version
nvm install 16
nvm alias default 16
node --version
# Each step uses the same `$BASH_ENV`, so need to modify it
echo 'export NVM_DIR="/opt/circleci/.nvm"' >> $BASH_ENV
echo "[ -s \"$NVM_DIR/nvm.sh\" ] && . \"$NVM_DIR/nvm.sh\"" >> $BASH_ENV
mvn --no-snapshot-updates --quiet verify -Psamples.circleci.node3 -Dorg.slf4j.simpleLogger.defaultLogLevel=error
else
@ -62,13 +84,6 @@ else
#sudo update-java-alternatives -s java-1.7.0-openjdk-amd64
java -version
# Install golang version 1.14
go version
sudo mkdir /usr/local/go1.14
wget -c https://dl.google.com/go/go1.14.linux-amd64.tar.gz -O - | sudo tar -xz -C /usr/local/go1.14
export PATH="/usr/local/go1.14/go/bin:$PATH"
go version
mvn --no-snapshot-updates --quiet verify -Psamples.circleci.others -Dorg.slf4j.simpleLogger.defaultLogLevel=error
mvn --no-snapshot-updates --quiet javadoc:javadoc -Psamples.circleci -Dorg.slf4j.simpleLogger.defaultLogLevel=error
fi

70
pom.xml
View File

@ -1172,7 +1172,6 @@
</property>
</activation>
<modules>
<module>samples/server/petstore/kotlin-springboot</module>
<module>samples/server/petstore/jaxrs/jersey2</module>
<module>samples/server/petstore/jaxrs/jersey2-useTags</module>
<module>samples/server/petstore/spring-mvc</module>
@ -1230,7 +1229,6 @@
<module>samples/server/petstore/scala-akka-http-server</module>
<module>samples/server/petstore/scalatra</module>
<module>samples/server/petstore/scala-finch</module>
<!--<module>samples/server/petstore/kotlin/vertx</module>-->
</modules>
</profile>
<!-- node 3 tests in CircleCI -->
@ -1247,6 +1245,33 @@
<module>samples/client/petstore/python</module>
<module>samples/client/petstore/python_disallowAdditionalPropertiesIfNotPresent</module>
<module>samples/openapi3/client/petstore/python</module>
<!-- TODO comment out below when the test for typescript-nestjs is ready
<module>samples/client/petstore/typescript-nestjs-v6-provided-in-root</module>-->
<!-- comment out due to error `npm run build`
<module>samples/client/petstore/typescript-jquery/npm</module>-->
<module>samples/client/petstore/typescript-angular-v7-provided-in-root</module>
<module>samples/client/petstore/typescript-angular-v11-provided-in-root</module>
<module>samples/openapi3/client/petstore/typescript/builds/default</module>
<module>samples/openapi3/client/petstore/typescript/tests/default</module>
<module>samples/openapi3/client/petstore/typescript/builds/jquery</module>
<module>samples/openapi3/client/petstore/typescript/tests/jquery</module>
<module>samples/openapi3/client/petstore/typescript/builds/object_params</module>
<module>samples/openapi3/client/petstore/typescript/tests/object_params</module>
<module>samples/openapi3/client/petstore/typescript/builds/inversify</module>
<!-- comment out due to failure in travis ci
<module>samples/openapi3/client/petstore/typescript/tests/inversify</module>
<module>samples/openapi3/client/petstore/typescript/tests/deno</module>-->
<module>samples/client/petstore/typescript-fetch/builds/default</module>
<module>samples/client/petstore/typescript-fetch/builds/es6-target</module>
<module>samples/client/petstore/typescript-fetch/builds/with-npm-version</module>
<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>
<module>samples/client/petstore/javascript-flowtyped</module>
<module>samples/client/petstore/javascript-es6</module>
<module>samples/client/petstore/javascript-promise-es6</module>
</modules>
</profile>
<!-- other tests in CircleCI -->
@ -1290,39 +1315,6 @@
<module>samples/client/petstore/java/microprofile-rest-client</module>
<module>samples/client/petstore/java/apache-httpclient</module>
<module>samples/client/petstore/groovy</module>
<!-- 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>
<module>samples/server/petstore/go-gin-api-server</module>
<module>samples/server/petstore/go-echo-server</module>
<!-- TODO comment out below when the test for typescript-nestjs is ready
<module>samples/client/petstore/typescript-nestjs-v6-provided-in-root</module>-->
<!-- comment out due to error `npm run build`
<module>samples/client/petstore/typescript-jquery/npm</module>-->
<module>samples/client/petstore/typescript-angular-v7-provided-in-root</module>
<module>samples/client/petstore/typescript-angular-v11-provided-in-root</module>
<module>samples/openapi3/client/petstore/typescript/builds/default</module>
<module>samples/openapi3/client/petstore/typescript/tests/default</module>
<module>samples/openapi3/client/petstore/typescript/builds/jquery</module>
<module>samples/openapi3/client/petstore/typescript/tests/jquery</module>
<module>samples/openapi3/client/petstore/typescript/builds/object_params</module>
<module>samples/openapi3/client/petstore/typescript/tests/object_params</module>
<module>samples/openapi3/client/petstore/typescript/builds/inversify</module>
<!-- comment out due to failure in travis ci
<module>samples/openapi3/client/petstore/typescript/tests/inversify</module>
<module>samples/openapi3/client/petstore/typescript/tests/deno</module>-->
<module>samples/client/petstore/typescript-fetch/builds/default</module>
<module>samples/client/petstore/typescript-fetch/builds/es6-target</module>
<module>samples/client/petstore/typescript-fetch/builds/with-npm-version</module>
<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 -->
@ -1356,6 +1348,8 @@
<module>samples/client/petstore/kotlin-threetenbp</module>
<module>samples/client/petstore/kotlin-uppercase-enum</module>
<!-- servers -->
<module>samples/server/petstore/kotlin-springboot</module>
<!--<module>samples/server/petstore/kotlin/vertx</module>-->
<!--<module>samples/server/petstore/erlang-server</module>-->
</modules>
</profile>
@ -1388,6 +1382,12 @@
<!--<module>samples/client/petstore/haskell-http-client</module>-->
<!-- servers -->
<!--<module>samples/server/petstore/haskell-servant</module>-->
<!-- test Go projects -->
<module>samples/client/petstore/go</module>
<module>samples/openapi3/client/petstore/go</module>
<module>samples/server/petstore/go-api-server</module>
<module>samples/server/petstore/go-gin-api-server</module>
<module>samples/server/petstore/go-echo-server</module>
</modules>
</profile>
<profile>