diff --git a/.github/workflows/samples-scala-client.yaml b/.github/workflows/samples-scala-client.yaml new file mode 100644 index 000000000000..b7638ef82828 --- /dev/null +++ b/.github/workflows/samples-scala-client.yaml @@ -0,0 +1,70 @@ +name: Samples Scala/sbt client + +on: + push: + paths: + - samples/client/petstore/scalaz/** + - samples/client/petstore/scala-pekko/** + - samples/client/petstore/scala-http4s/** + - samples/client/petstore/scala-sttp4-jsoniter/** + - samples/client/petstore/scala-akka/** + - samples/client/petstore/scala-sttp/** + - samples/client/petstore/scala-sttp-circe/** + - samples/client/petstore/scala-sttp4/** + pull_request: + paths: + - samples/client/petstore/scalaz/** + - samples/client/petstore/scala-pekko/** + - samples/client/petstore/scala-http4s/** + - samples/client/petstore/scala-sttp4-jsoniter/** + - samples/client/petstore/scala-akka/** + - samples/client/petstore/scala-sttp/** + - samples/client/petstore/scala-sttp-circe/** + - samples/client/petstore/scala-sttp4/** +jobs: + build: + name: Build sbt/Scala + runs-on: ubuntu-latest + strategy: + fail-fast: false + matrix: + sample: + # clients + - samples/client/petstore/scalaz + - samples/client/petstore/scala-pekko + - samples/client/petstore/scala-http4s + - samples/client/petstore/scala-sttp4-jsoniter + - samples/client/petstore/scala-akka + - samples/client/petstore/scala-sttp + - samples/client/petstore/scala-sttp-circe + - samples/client/petstore/scala-sttp4 + services: + petstore-api: + image: swaggerapi/petstore + ports: + - 80:8080 + env: + SWAGGER_HOST: http://petstore.swagger.io + SWAGGER_BASE_PATH: /v2 + steps: + - uses: actions/checkout@v5 + - name: Add hosts to /etc/hosts + run: | + sudo echo "127.0.0.1 petstore.swagger.io" | sudo tee -a /etc/hosts + - uses: actions/setup-java@v5 + with: + distribution: 'temurin' + java-version: 11 + - name: Setup sbt launcher + uses: sbt/setup-sbt@v1 + - name: Cache maven dependencies + uses: actions/cache@v4 + env: + cache-name: maven-repository + with: + path: | + ~/.ivy2 + key: ${{ runner.os }}-${{ github.job }}-${{ env.cache-name }}-${{ hashFiles('**/build.sbt') }} + - name: Build and test + working-directory: ${{ matrix.sample }} + run: sbt -v test diff --git a/.github/workflows/samples-scala.yaml b/.github/workflows/samples-scala-server.yaml similarity index 71% rename from .github/workflows/samples-scala.yaml rename to .github/workflows/samples-scala-server.yaml index 91b9b864f687..86544babdca4 100644 --- a/.github/workflows/samples-scala.yaml +++ b/.github/workflows/samples-scala-server.yaml @@ -1,29 +1,20 @@ -name: Samples Scala/sbt +name: Samples Scala/sbt server on: push: paths: - - 'samples/client/petstore/scala**' - 'samples/server/petstore/scala**' pull_request: paths: - - 'samples/client/petstore/scala**' - 'samples/server/petstore/scala**' jobs: build: - name: Build sbt/Scala client, servers + name: Build sbt/Scala runs-on: ubuntu-latest strategy: fail-fast: false matrix: sample: - # clients - - samples/client/petstore/scalaz - - samples/client/petstore/scala-pekko - - samples/client/petstore/scala-http4s - - samples/client/petstore/scala-sttp4-jsoniter - #- samples/client/petstore/scala-sttp - #- samples/client/petstore/scala-sttp-circe # servers - samples/server/petstore/scala-play-server - samples/server/petstore/scala-akka-http-server diff --git a/CI/circle_parallel.sh b/CI/circle_parallel.sh index d7cd03c5686a..58c1584b99b7 100755 --- a/CI/circle_parallel.sh +++ b/CI/circle_parallel.sh @@ -116,9 +116,4 @@ else echo "Running node $NODE_INDEX ..." java -version - (cd samples/client/petstore/scala-akka && mvn integration-test) - (cd samples/client/petstore/scala-sttp && mvn integration-test) - (cd samples/client/petstore/scala-sttp-circe && mvn integration-test) - (cd samples/client/petstore/scala-sttp4 && mvn integration-test) - fi diff --git a/samples/client/petstore/scala-akka/.openapi-generator-ignore b/samples/client/petstore/scala-akka/.openapi-generator-ignore index 69a08439a3b8..3ea6f8c30659 100644 --- a/samples/client/petstore/scala-akka/.openapi-generator-ignore +++ b/samples/client/petstore/scala-akka/.openapi-generator-ignore @@ -22,3 +22,5 @@ # Then explicitly reverse the ignore rule for a single file: #!docs/README.md pom.xml + + diff --git a/samples/server/petstore/scala-cask/.openapi-generator-ignore b/samples/server/petstore/scala-cask/.openapi-generator-ignore index 7484ee590a38..c5b04829c20a 100644 --- a/samples/server/petstore/scala-cask/.openapi-generator-ignore +++ b/samples/server/petstore/scala-cask/.openapi-generator-ignore @@ -21,3 +21,6 @@ #docs/*.md # Then explicitly reverse the ignore rule for a single file: #!docs/README.md +# +# +#