From 672cc29f734ca0f1c916491782558f91ee633381 Mon Sep 17 00:00:00 2001 From: wing328 Date: Mon, 25 Sep 2017 12:49:58 +0800 Subject: [PATCH] [Bash] Add test setting for Bash client (#6558) * add pom.xml and travis.yml for bash * create travis.yml.bak, test .travis.yml.bash * restore travis.yml --- .travis.yml.bash | 37 ++ pom.xml.bash | 930 +++++++++++++++++++++++++++++++++++++++++++++++ 2 files changed, 967 insertions(+) create mode 100644 .travis.yml.bash create mode 100644 pom.xml.bash diff --git a/.travis.yml.bash b/.travis.yml.bash new file mode 100644 index 00000000000..f224cac3958 --- /dev/null +++ b/.travis.yml.bash @@ -0,0 +1,37 @@ +sudo: required +language: java +jdk: + - openjdk8 + +cache: + directories: + - $HOME/.m2 + - $HOME/.ivy2 + +services: + - docker + +addons: + hosts: + - petstore.swagger.io + +before_install: + # 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 + - docker ps -a + # Add bats test framework and cURL for Bash script integration tests + - sudo add-apt-repository ppa:duggan/bats --yes + - sudo apt-get update -qq + - sudo apt-get install -qq bats + - sudo apt-get install -qq curl + + # show host table to confirm petstore.swagger.io is mapped to localhost + - cat /etc/hosts + +script: + # fail fast + - set -e + # run integration tests defined in maven pom.xml + - cp pom.xml.bash pom.xml + - mvn --batch-mode verify -Psamples diff --git a/pom.xml.bash b/pom.xml.bash new file mode 100644 index 00000000000..6d43fe6829d --- /dev/null +++ b/pom.xml.bash @@ -0,0 +1,930 @@ + + + org.sonatype.oss + oss-parent + 5 + + 4.0.0 + io.swagger + swagger-codegen-project + pom + swagger-codegen-project + 2.3.0-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 + + + + fehguy + Tony Tam + fehguy@gmail.com + + + wing328 + William Cheng + wing328hk@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} + + + net.revelc.code + formatter-maven-plugin + + + + 1.7 + 1.7 + 1.7 + LF + + + + org.apache.maven.plugins + maven-checkstyle-plugin + 2.17 + + + validate + validate + + google_checkstyle.xml + + ${project.build.sourceDirectory} + UTF-8 + true + true + false + + + check + + + + + + com.puppycrawl.tools + checkstyle + 6.19 + + + + + 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.6.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 + + + + + + org.apache.maven.plugins + maven-enforcer-plugin + 1.4.1 + + + enforce-versions + + enforce + + + + + 3.2.5 + + + + + + + + + + + net.revelc.code + formatter-maven-plugin + 0.5.2 + + + + + + + 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 + + + + bash-client + + + env + java + + + + samples/client/petstore/bash + + + + clojure-client + + + env + clojure + + + + samples/client/petstore/clojure + + + + haskell-http-client + + + env + haskell-http-client + + + + samples/client/petstore/haskell-http-client + + + + haskell-http-client-integration-test + + + env + haskell-http-client + + + + samples/client/petstore/haskell-http-client/tests-integration + + + + java-client-jersey1 + + + env + java + + + + samples/client/petstore/java/jersey1 + + + + java-client-jersey2 + + + env + java + + + + samples/client/petstore/java/jersey2 + + + + java-client-jersey2-java6 + + + env + java + + + + samples/client/petstore/java/jersey2-java6 + + + + java-client-okhttp-gson + + + env + java + + + + samples/client/petstore/java/okhttp-gson + + + + java-client-okhttp-gson-parcelable + + + env + java + + + + samples/client/petstore/java/okhttp-gson/parcelableModel + + + + 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 + + + + java-msf4j-server + + + env + java + + + + samples/server/petstore/java-msf4/ + + + + jaxrs-cxf-server + + + env + java + + + + samples/server/petstore/jaxrs-cxf + + + + jaxrs-resteasy-server + + + env + java + + + + samples/server/petstore/jaxrs-resteasy/default + + + + jaxrs-resteasy-server-joda + + + env + java + + + + samples/server/petstore/jaxrs-resteasy/joda + + + + jaxrs-resteasy-eap-server + + + env + java + + + + samples/server/petstore/jaxrs-resteasy/eap + + + + jaxrs-resteasy-eap-server-joda + + + env + java + + + + samples/server/petstore/jaxrs-resteasy/eap-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-angularjs/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-beanvalidation + + + env + java + + + + samples/server/petstore/springboot-beanvalidation + + + + springboot + + + env + java + + + + samples/server/petstore/springboot + + + + spring-cloud + + + env + java + + + + samples/client/petstore/spring-cloud + + + + scalatra-server + + + env + java + + + + samples/server/petstore/scalatra + + + + java-inflector + + + env + java + + + + samples/server/petstore/java-inflector + + + + java-undertowr + + + env + java + + + + samples/server/petstore/undertow + + + + samples + + + env + samples + + + + samples/client/petstore/bash + + + + + 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.32 + 2.11.1 + 3.3.0 + 1.5.16 + 2.4 + 1.2 + 4.8.1 + 2.8.9 + 1.0.0 + 3.4 + 1.7.12 + 3.2.1 + 1.12 + 6.9.6 + 2.19.1 + 1.25 + 0.9.10 + +