All Projects → jpomykala → spring-jooq-flyway-testcontainers-junit5

jpomykala / spring-jooq-flyway-testcontainers-junit5

Licence: other
🚀 Example project with configured Spring Boot, JooQ, TestContainers, MySQL container and JUnit5

Programming Languages

java
68154 projects - #9 most used programming language

Projects that are alternatives of or similar to spring-jooq-flyway-testcontainers-junit5

testing-spring-boot-applications-masterclass
🍃 Everything You Need to Know About Testing Spring Boot Applications
Stars: ✭ 185 (+537.93%)
Mutual labels:  junit, testcontainers, junit5
flyway-junit5-extensions
Flyway JUnit 5 Extension to clean / migrate your database in tests.
Stars: ✭ 14 (-51.72%)
Mutual labels:  junit, flyway, junit5
advanced-spring-scaffold
This project provides an advanced baseline to help you kick start a Spring project.
Stars: ✭ 21 (-27.59%)
Mutual labels:  flyway, testcontainers, junit5
hivemq-testcontainer
Automatic starting HiveMQ docker containers for JUnit4 and JUnit5 tests. This enables testing MQTT client applications and integration testing of custom HiveMQ extensions.
Stars: ✭ 17 (-41.38%)
Mutual labels:  testcontainers, junit5
junit5-kubernetes
Use kubernetes pod from your Junit5 test classes
Stars: ✭ 40 (+37.93%)
Mutual labels:  junit, junit5
manon
🧪 Play with SpringBoot 2, JWT, Querydsl, GraphQL, Docker, ELK, PostgreSQL, MariaDB, Redis, MongoDB, Flyway, Maven, Gradle, TestNG, JUnit5, JaCoCo, GreenMail, CI, Quality Gates, Prometheus, Gatling, etc.
Stars: ✭ 26 (-10.34%)
Mutual labels:  flyway, junit5
junit5-demo
Demos for JUnit 5
Stars: ✭ 46 (+58.62%)
Mutual labels:  junit, junit5
webdrivermanager-examples
JUnit tests with Selenium WebDriver and WebDriverManager
Stars: ✭ 94 (+224.14%)
Mutual labels:  junit, junit5
osgi-test
Testing support for OSGi. Includes JUnit 4 and JUnit 5 support and AssertJ support.
Stars: ✭ 22 (-24.14%)
Mutual labels:  junit, junit5
bdd
JUnit 5 based BDD library to create and run stories and behaviors a.k.a BDD specification tests
Stars: ✭ 25 (-13.79%)
Mutual labels:  junit, junit5
ForgeModdingSkeleton
Skeletons for building Forge mods
Stars: ✭ 21 (-27.59%)
Mutual labels:  junit, junit5
jpa-unit
JUnit extension to test javax.persistence entities
Stars: ✭ 28 (-3.45%)
Mutual labels:  junit, junit5
Library-Spring
The library web application where you can borrow books. It's Spring MVC and Hibernate project.
Stars: ✭ 73 (+151.72%)
Mutual labels:  junit, flyway
flywaydb.org
The main marketing and documentation site for Flyway by Redgate
Stars: ✭ 41 (+41.38%)
Mutual labels:  flyway
travels-api
API for Travels Management - UFLA Comp Jr/20 anniversary event
Stars: ✭ 22 (-24.14%)
Mutual labels:  java-11
Pbbl
A thread-safe ByteBuffer pool that allows for the automatic reuse of ByteBuffers, which can be over 30x faster than having to allocate a new ByteBuffer when needed.
Stars: ✭ 32 (+10.34%)
Mutual labels:  java-11
spring-r2dbc-sample
Code samples for demonstrating R2dbc, Spring R2dbc, and Spring Data R2dbc.
Stars: ✭ 105 (+262.07%)
Mutual labels:  testcontainers
spring-cloud-microservices-on-kubernetes
My Best Practices in development and deployment of Spring Cloud Microservices on Kubernetes.
Stars: ✭ 19 (-34.48%)
Mutual labels:  flyway
pro.fessional.wings
WingsBoot=BKB+飞鞋+SpringBoot。其核心价值是:①使团队快速实现业务目标;②快速偿还技术债务;③安全的面向程序和业务重构。
Stars: ✭ 78 (+168.97%)
Mutual labels:  jooq
Programacion-AlumnosClase
Ejemplo inicial de Programación Orientada a Objetos, con Java. Nuestra primeras clases, con usos, abusos, y algunos tests en 1DAM. Curso 2021-2022.
Stars: ✭ 13 (-55.17%)
Mutual labels:  junit5

spring-jooq-flyway-testcontainers-junit5

Example project with configured Spring Boot, JooQ, TestContainers, flyway (as maven plugin) MySQL container and JUnit5 🚀

Used versions

<spring-boot.version>2.1.1</spring-boot.version>
<java.version>11</java.version>
<org.flyway.version>5.2.4</org.flyway.version>
<org.jooq.version>3.11.7</org.jooq.version>
<mysql-connector-java.version>8.0.11</mysql-connector-java.version>
<testcontainers.version>1.10.5</testcontainers.version>

Running

mvn clean test

Test loads first migration V1__Init.sql manually.

Main test configuration

@ContextConfiguration(initializers = AbstractTestConfiguration.Initializer.class)
@AutoConfigureTestDatabase(replace = AutoConfigureTestDatabase.Replace.NONE)
@JooqTest
public abstract class AbstractTestConfiguration {

  @ClassRule
  public static MySQLContainer mysql = new MySQLContainer().withDatabaseName("playground");


  public static class Initializer implements ApplicationContextInitializer<ConfigurableApplicationContext> {

    @Override
    public void initialize(@NotNull ConfigurableApplicationContext configurableApplicationContext) {
      mysql.start();
      configurableApplicationContext.getEnvironment().getSystemProperties().put("spring.datasource.url", mysql.getJdbcUrl() + "?useSSL=false");
      configurableApplicationContext.getEnvironment().getSystemProperties().put("spring.datasource.username", mysql.getUsername());
      configurableApplicationContext.getEnvironment().getSystemProperties().put("spring.datasource.password", mysql.getPassword());
    }
  }
}
Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].