Skip to content

simplify bundling endpoints and fix variable ordering (#1112) #966

simplify bundling endpoints and fix variable ordering (#1112)

simplify bundling endpoints and fix variable ordering (#1112) #966

Workflow file for this run

name: Scala CI
on:
push:
pull_request:
jobs:
sbt_formatChecks_dependencyTree:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Set up JDK 11
uses: actions/setup-java@v3
with:
java-version: 11
distribution: 'temurin'
- name: Create sbt dependencyTree
env:
CI: true
run: |
sbt -Dsbt.log.format=false 'set asciiGraphWidth := 10000' 'dependencyTree'
- name: Verify scalafix passes
env:
CI: true
run: |
sbt -Dsbt.log.format=false generateRoutesFile scalafmtCheckAll scalafmtSbtCheck 'scalafixAll --check'
sbt_tests_jacoco:
runs-on: ubuntu-latest
services:
postgis11:
image: postgis/postgis:13-3.3
ports:
- 5432:5432
env:
POSTGRES_DB: mr_test
POSTGRES_USER: osm
POSTGRES_PASSWORD: osm
strategy:
matrix:
java: [ 11 ]
steps:
- uses: actions/checkout@v3
- name: Set up JDK ${{ matrix.java }}
uses: actions/setup-java@v3
with:
java-version: ${{ matrix.java }}
distribution: 'temurin'
- name: Run sbt tests with jacoco analysis
env:
CI: true
MR_TEST_DB_NAME: "mr_test"
MR_TEST_DB_USER: "osm"
MR_TEST_DB_PASSWORD: "osm"
run: |
sbt -Dsbt.log.format=false jacoco
build:
runs-on: ubuntu-latest
services:
postgis11:
image: postgis/postgis:13-3.3
ports:
- 5432:5432
env:
POSTGRES_DB: mr_test
POSTGRES_USER: osm
POSTGRES_PASSWORD: osm
strategy:
matrix:
java: [11]
steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v3
with:
repository: 'osmlab/maproulette-java-client'
path: 'java-client'
- name: Set up JDK ${{ matrix.java }}
uses: actions/setup-java@v3
with:
java-version: ${{ matrix.java }}
distribution: 'temurin'
- name: Run sbt compile
env:
CI: true
run: sbt -Dsbt.log.format=false compile
- name: Create the dev.conf
run: |
touch ./conf/dev.conf
echo 'include "application.conf"' >> ./conf/dev.conf
echo 'maproulette {' >> ./conf/dev.conf
echo ' debug=true' >> ./conf/dev.conf
echo ' bootstrap=true' >> ./conf/dev.conf
echo '}' >> ./conf/dev.conf
- name: Run maproulette and the maproulette-java-client integration tests
env:
# maproulette overrides
CI: true
SBT_OPTS: "-Xms512M -Xmx1024M -Xss2M -XX:MaxMetaspaceSize=1024M"
MR_SUPER_KEY: 1234
MR_DATABASE_URL: "jdbc:postgresql://localhost:5432/mr_test"
MR_DATABASE_USERNAME: "osm"
MR_DATABASE_PASSWORD: "osm"
# maproulette-java-client overrides
host: 127.0.0.1
scheme: http
apiKey: 1234
run: |
sbt -Dsbt.log.format=false -Dconfig.file=./conf/dev.conf run &
sleep 10
pushd java-client
./gradlew --info --project-prop runIntegrationTests \
clean integrationTest \
--tests '*BatchUploaderIntegrationTest*' \
--tests '*ChallengeAPIIntegrationTest*' \
--tests '*ProjectAPIIntegrationTest*'