Skip to content

Commit

Permalink
fix: Integration tests not working correctly
Browse files Browse the repository at this point in the history
  • Loading branch information
johanandren committed Mar 12, 2024
1 parent bcdea07 commit 7d6ec71
Show file tree
Hide file tree
Showing 7 changed files with 45 additions and 44 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/mysql-tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ jobs:
run: ./scripts/launch-mysql.sh

- name: Run Integration tests for ${{ matrix.name }}
run: sbt "testOnly akka.persistence.jdbc.integration.MySQL*" ${{ matrix.extraOpts }} -J-XX:+UnlockExperimentalVMOptions -J-XX:+UseJVMCICompiler
run: sbt "integration/testOnly akka.persistence.jdbc.integration.MySQL*" ${{ matrix.extraOpts }} -J-XX:+UnlockExperimentalVMOptions -J-XX:+UseJVMCICompiler

- name: Print logs on failure
if: ${{ failure() }}
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/oracle-tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ jobs:
run: ./scripts/launch-oracle.sh

- name: Run Integration tests for ${{ matrix.name }}
run: sbt "testOnly akka.persistence.jdbc.integration.Oracle*" ${{ matrix.extraOpts }} -J-XX:+UnlockExperimentalVMOptions -J-XX:+UseJVMCICompiler
run: sbt "integration/testOnly akka.persistence.jdbc.integration.Oracle*" ${{ matrix.extraOpts }} -J-XX:+UnlockExperimentalVMOptions -J-XX:+UseJVMCICompiler

- name: Print logs on failure
if: ${{ failure() }}
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/postgres-tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ jobs:
run: ./scripts/launch-postgres.sh

- name: Run Integration tests for ${{ matrix.name }}
run: sbt "testOnly akka.persistence.jdbc.integration.Postgres*" ${{ matrix.extraOpts }} -J-XX:+UnlockExperimentalVMOptions -J-XX:+UseJVMCICompiler
run: sbt "integration/testOnly akka.persistence.jdbc.integration.Postgres*" ${{ matrix.extraOpts }} -J-XX:+UnlockExperimentalVMOptions -J-XX:+UseJVMCICompiler

- name: Print logs on failure
if: ${{ failure() }}
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/sqlserver-tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ jobs:
run: ./scripts/launch-sqlserver.sh

- name: Run Integration tests for ${{ matrix.name }}
run: sbt "testOnly akka.persistence.jdbc.integration.SqlServer*" ${{ matrix.extraOpts }} -J-XX:+UnlockExperimentalVMOptions -J-XX:+UseJVMCICompiler
run: sbt "integration/testOnly akka.persistence.jdbc.integration.SqlServer*" ${{ matrix.extraOpts }} -J-XX:+UnlockExperimentalVMOptions -J-XX:+UseJVMCICompiler

- name: Print logs on failure
if: ${{ failure() }}
Expand Down
2 changes: 1 addition & 1 deletion build.sbt
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ lazy val integration = project
.settings(IntegrationTests.settings)
.settings(name := "akka-persistence-jdbc-integration", libraryDependencies ++= Dependencies.Libraries)
.disablePlugins(MimaPlugin, SitePlugin, CiReleasePlugin)
.dependsOn(core)
.dependsOn(core % "compile->compile;test->test")

lazy val migrator = project
.in(file("migrator"))
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ package akka.persistence.jdbc.integration
import com.typesafe.config.ConfigFactory
import akka.actor.ActorSystem
import akka.persistence.jdbc.state.scaladsl.JdbcDurableStateSpec
import akka.persistence.jdbc.testkit.internal.Mysql
import akka.persistence.jdbc.testkit.internal.MySQL

class MySQLScalaJdbcDurableStateStoreQueryTest
extends JdbcDurableStateSpec(ConfigFactory.load("mysql-shared-db-application.conf"), MySQL) {
Expand Down
77 changes: 39 additions & 38 deletions scripts/docker-compose.yml
Original file line number Diff line number Diff line change
@@ -1,41 +1,42 @@
postgres:
image: postgres:latest
container_name: postgres-test
environment:
- "TZ=Europe/Amsterdam"
- "POSTGRES_USER=docker"
- "POSTGRES_PASSWORD=docker"
ports:
- "5432:5432" # credentials (docker:docker)
services:
postgres:
image: postgres:latest
container_name: postgres-test
environment:
- "TZ=Europe/Amsterdam"
- "POSTGRES_USER=docker"
- "POSTGRES_PASSWORD=docker"
ports:
- "5432:5432" # credentials (docker:docker)

mysql:
image: mysql:latest
container_name: mysql-test
environment:
- "TZ=Europe/Amsterdam"
- "MYSQL_ROOT_PASSWORD=root"
- "MYSQL_DATABASE=docker"
ports:
- "3306:3306" # credentials (root:root)
mysql:
image: mysql:latest
container_name: mysql-test
environment:
- "TZ=Europe/Amsterdam"
- "MYSQL_ROOT_PASSWORD=root"
- "MYSQL_DATABASE=docker"
ports:
- "3306:3306" # credentials (root:root)

oracle:
image: oracleinanutshell/oracle-xe-11g
container_name: oracle-test
environment:
- "TZ=Europe/Amsterdam"
- "DBCA_TOTAL_MEMORY=1024"
ports:
- "1521:1521" # DB_CONN: credentials (system:oracle)
oracle:
image: oracleinanutshell/oracle-xe-11g
container_name: oracle-test
environment:
- "TZ=Europe/Amsterdam"
- "DBCA_TOTAL_MEMORY=1024"
ports:
- "1521:1521" # DB_CONN: credentials (system:oracle)

sqlserver:
image: topaztechnology/mssql-server-linux
container_name: sqlserver-test
environment:
- "TZ=Europe/Amsterdam"
- "DBCA_TOTAL_MEMORY=1024"
- "ACCEPT_EULA=Y"
- "SQL_USER=docker"
- "SQL_PASSWORD=docker"
- "SQL_DB=docker"
ports:
- "1433:1433" # credentials (docker:docker)
sqlserver:
image: topaztechnology/mssql-server-linux
container_name: sqlserver-test
environment:
- "TZ=Europe/Amsterdam"
- "DBCA_TOTAL_MEMORY=1024"
- "ACCEPT_EULA=Y"
- "SQL_USER=docker"
- "SQL_PASSWORD=docker"
- "SQL_DB=docker"
ports:
- "1433:1433" # credentials (docker:docker)

0 comments on commit 7d6ec71

Please sign in to comment.