bump: Milestone dependencies (#14) #32
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Validate and test | |
on: | |
pull_request: | |
push: | |
branches: | |
- main | |
tags-ignore: [ v.* ] | |
jobs: | |
check-code-style: | |
name: Checks | |
runs-on: ubuntu-18.04 | |
if: github.repository == 'akka/akka-projection-testing' | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v2 | |
with: | |
# we don't know what commit the last tag was it's safer to get entire repo so previousStableVersion resolves | |
fetch-depth: 0 | |
- name: Checkout GitHub merge | |
if: github.event.pull_request | |
run: |- | |
git fetch origin pull/${{ github.event.pull_request.number }}/merge:scratch | |
git checkout scratch | |
- name: Set up JDK 11 | |
uses: olafurpg/setup-scala@v10 | |
with: | |
java-version: adopt@1.11.0-9 | |
- name: Cache Coursier cache | |
uses: coursier/cache-action@v5 | |
- name: Code style check | |
run: |- | |
cp .jvmopts-ci .jvmopts | |
sbt verifyCodeStyle | |
test: | |
name: Run tests | |
runs-on: ubuntu-18.04 | |
if: github.repository == 'akka/akka-projection-testing' | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v2 | |
with: | |
fetch-depth: 0 | |
- name: Checkout GitHub merge | |
if: github.event.pull_request | |
run: |- | |
git fetch origin pull/${{ github.event.pull_request.number }}/merge:scratch | |
git checkout scratch | |
- name: Set up JDK 11 | |
uses: olafurpg/setup-scala@v10 | |
with: | |
java-version: adopt@1.11.0-9 | |
- name: Cache Coursier cache | |
uses: coursier/cache-action@v5 | |
- name: docker-compose | |
run: |- | |
docker-compose -f docker/docker-compose-postgres.yml up -d | |
# TODO: could we poll the port instead of sleep? | |
sleep 10 | |
docker exec -i docker_postgres-db_1 psql -U postgres -t < ddl-scripts/create_tables_postgres.sql | |
- name: docker-compose | |
run: docker-compose -f docker/docker-compose-cassandra.yml up -d | |
- name: test | |
run: sbt -jvm-opts .jvmopts-ci test | |
- name: after failure | |
if: ${{ failure() }} | |
run: docker-compose logs |