From 5a36f7435da38da7ce84c1e30208c61b25acddec Mon Sep 17 00:00:00 2001 From: wing328 Date: Sun, 23 Apr 2017 15:59:16 +0800 Subject: [PATCH] better circleci configuration (#5456) --- circle.yml | 32 +- pom.xml.circleci | 737 +++++++++++++++++++++++++++++++++++++++++++++++ 2 files changed, 747 insertions(+), 22 deletions(-) create mode 100644 pom.xml.circleci diff --git a/circle.yml b/circle.yml index dadbcaca00..a202b2986c 100644 --- a/circle.yml +++ b/circle.yml @@ -1,14 +1,7 @@ -# work in progress: the goal is to move all the existing tests -# handled by travis-ci to circle CI so that travis-ci can test -# objc/swift API client instead +# Java client, server tests machine: - environment: - _JAVA_OPTIONS: "-Xms512m -Xmx1024m" java: - # TODO we also need to test oraclejdk8 - version: oraclejdk7 - node: - version: 5.0.0 + version: openjdk8 services: - docker # Override /etc/hosts @@ -17,15 +10,8 @@ machine: dependencies: cache_directories: - - ~/.jspm - - ~/.npm - - ~/builder - ~/.m2 pre: - - export MAVEN_OPTS="-Xmx512m -XX:MaxPermSize=256m" - - gem install bundler - - npm install -g typescript - - sudo pip install virtualenv # to run petstore server locally via docker - docker pull swaggerapi/petstore - docker run -d -e SWAGGER_HOST=http://petstore.swagger.io -e SWAGGER_BASE_PATH=/v2 -p 80:8080 swaggerapi/petstore @@ -33,12 +19,14 @@ dependencies: # show host table to confirm petstore.swagger.io is mapped to localhost - cat /etc/hosts override: - #- rvm --default use 2.1.0 - #- ruby -v + - cp pom.xml.circleci pom.xml test: override: - - mvn verify -Psamples - #- mvn -q clean install - #- jdk_switcher use oraclejdk8 - #- mvn -q clean install + # test with jdk8 + - java -version + - mvn -q clean verify -Psamples + # test with jdk7 + - sudo update-java-alternatives -s java-1.7.0-openjdk-amd64 + - java -version + - mvn -q clean verify -Psamples diff --git a/pom.xml.circleci b/pom.xml.circleci new file mode 100644 index 0000000000..56e51dd57e --- /dev/null +++ b/pom.xml.circleci @@ -0,0 +1,737 @@ + + + org.sonatype.oss + oss-parent + 5 + + 4.0.0 + io.swagger + swagger-codegen-project + pom + swagger-codegen-project + 2.2.2-SNAPSHOT + https://github.com/swagger-api/swagger-codegen + + scm:git:git@github.com:swagger-api/swagger-codegen.git + scm:git:git@github.com:swagger-api/swagger-codegen.git + https://github.com/swagger-api/swagger-codegen + + + 2.2.0 + + + + fehguy + Tony Tam + fehguy@gmail.com + + + + github + https://github.com/swagger-api/swagger-codegen/issues + + + + swagger-swaggersocket + https://groups.google.com/forum/#!forum/swagger-swaggersocket + + + + + Apache License 2.0 + http://www.apache.org/licenses/LICENSE-2.0.html + repo + + + + src/main/java + target/classes + + + org.jvnet.wagon-svn + wagon-svn + 1.8 + + + org.apache.maven.wagon + wagon-ssh-external + 1.0-alpha-6 + + + org.apache.maven.wagon + wagon-webdav + 1.0-beta-1 + + + install + target + ${project.artifactId}-${project.version} + + + org.apache.maven.plugins + maven-surefire-plugin + ${surefire-version} + + none:none + -XX:+StartAttachListener + + + + test-testng + test + + test + + + none:none + org.testng:testng + + + + + + maven-dependency-plugin + + + package + + copy-dependencies + + + ${project.build.directory}/lib + + + + + + maven-compiler-plugin + 3.5.1 + + 1.7 + 1.7 + + + + org.apache.maven.plugins + maven-jar-plugin + 3.0.2 + + + + development + ${project.url} + ${project.version} + io.swagger + + + + + + org.apache.maven.plugins + maven-site-plugin + 3.5.1 + + + org.apache.maven.plugins + maven-release-plugin + 2.5.3 + + + + org.apache.maven.plugins + maven-javadoc-plugin + 2.10.4 + + true + 1.7 + UTF-8 + 1g + ${javadoc.package.exclude} + + + + attach-javadocs + verify + + jar + + + + + + org.apache.maven.plugins + maven-source-plugin + 3.0.1 + + + attach-sources + verify + + jar-no-fork + + + + + + + + + release-profile + + true + + + + + net.alchim31.maven + scala-maven-plugin + + + + compile + testCompile + + + + + + + org.codehaus.mojo + build-helper-maven-plugin + + + add-source + prepare-package + + add-source + + + + src/main/scala + + + + + + + + + + release-sign-artifacts + + + performRelease + true + + + + + + org.apache.maven.plugins + maven-gpg-plugin + + + sign-artifacts + verify + + sign + + + + + + + + + + android-client + + + env + java + + + + samples/client/petstore/android/volley + + + + clojure-client + + + env + clojure + + + + samples/client/petstore/clojure + + + + java-client-jersey1 + + + env + java + + + + samples/client/petstore/java/jersey1 + + + + java-client-jersey2 + + + env + java + + + + samples/client/petstore/java/jersey2 + + + + java-client-okhttp-gson + + + env + java + + + + samples/client/petstore/java/okhttp-gson + + + + java-client-retrofit + + + env + java + + + + samples/client/petstore/java/retrofit + + + + java-client-retrofit2 + + + env + java + + + + samples/client/petstore/java/retrofit2 + + + + java-client-retrofit2-rx + + + env + java + + + + samples/client/petstore/java/retrofit2rx + + + + java-client-feign + + + env + java + + + + samples/client/petstore/java/feign + + + + javascript-client + + + env + javascript + + + + samples/client/petstore/javascript + + + + scala-client + + + env + scala + + + + samples/client/petstore/scala + + + + objc-client + + + env + objc + + + + samples/client/petstore/objc/default/SwaggerClientTests + + + + swift-client + + + env + swift + + + + samples/client/petstore/swift/default/SwaggerClientTests + + + + jaxrs-resteasy-server + + + env + java + + + + samples/server/petstore/jaxrs-resteasy/default + + + + jaxrs-resteasy-server-joda + + + env + java + + + + samples/server/petstore/jaxrs-resteasy/joda + + + + jaxrs-server + + + env + java + + + + samples/server/petstore/jaxrs/jersey2 + + + + jaxrs-server-jersey1 + + + env + java + + + + samples/server/petstore/jaxrs/jersey1 + + + + typescript-fetch-client-tests-default + + + env + java + + + + samples/client/petstore/typescript-fetch/tests/default + + + + typescript-fetch-client-builds-default + + + env + java + + + + samples/client/petstore/typescript-fetch/builds/default + + + + typescript-fetch-client-builds-es6-target + + + env + java + + + + samples/client/petstore/typescript-fetch/builds/es6-target + + + + typescript-fetch-client-builds-with-npm-version + + + env + java + + + + samples/client/petstore/typescript-fetch/builds/with-npm-version + + + + typescript-angular-client + + + env + java + + + + samples/client/petstore/typescript-angular/npm + + + + typescript-node-npm-client + + + env + java + + + + samples/client/petstore/typescript-node/npm + + + + python-client + + + env + java + + + + samples/client/petstore/python + + + + ruby-client + + + env + java + + + + samples/client/petstore/ruby + + + + go-client + + + env + java + + + + samples/client/petstore/go + + + + spring-mvc + + + env + java + + + + samples/server/petstore/spring-mvc + + + + springboot + + + env + java + + + + samples/server/petstore/springboot + + + + spring-cloud + + + env + java + + + + samples/client/petstore/spring-cloud + + + + scalatra-server + + + env + java + + + + samples/server/petstore/scalatra + + + + samples + + + env + samples + + + + + + samples/client/petstore/android/volley + + samples/client/petstore/java/feign + samples/client/petstore/java/jersey1 + samples/client/petstore/java/jersey2 + samples/client/petstore/java/okhttp-gson + samples/client/petstore/java/retrofit + samples/client/petstore/java/retrofit2 + samples/client/petstore/java/retrofit2rx + + + samples/server/petstore/jaxrs/jersey1 + samples/server/petstore/jaxrs/jersey2 + samples/server/petstore/jaxrs-resteasy/default + samples/server/petstore/jaxrs-resteasy/joda + samples/server/petstore/spring-mvc + samples/client/petstore/spring-cloud + samples/server/petstore/springboot + + + + + + + + modules/swagger-codegen + modules/swagger-codegen-cli + modules/swagger-codegen-maven-plugin + modules/swagger-generator + + + target/site + + + net.alchim31.maven + scala-maven-plugin + ${scala-maven-plugin-version} + + + org.apache.maven.plugins + maven-jxr-plugin + 2.5 + + true + + + + org.apache.maven.plugins + maven-project-info-reports-plugin + 2.9 + + + + project-team + + + + + + + + + + junit + junit + ${junit-version} + test + + + org.testng + testng + ${testng-version} + test + + + org.jmockit + jmockit + ${jmockit-version} + test + + + + + + sonatype-snapshots + https://oss.sonatype.org/content/repositories/snapshots + + true + + + + + 1.0.22 + 2.11.1 + 2.3.4 + 1.5.9 + 2.4 + 1.2 + 4.8.1 + 1.0.0 + 3.4 + 1.7.12 + 3.2.1 + 1.12 + 6.9.6 + 2.19.1 + 1.25 + 0.9.10 + +