Class OracleDatabaseRule
java.lang.Object
org.junit.rules.ExternalResource
org.jdbi.v3.testing.JdbiRule
org.jdbi.v3.oracle12.OracleDatabaseRule
- All Implemented Interfaces:
org.junit.rules.TestRule
JUnit 4 Helper for a database managed by testcontainers.
-
Constructor Summary
Constructors -
Method Summary
Methods inherited from class JdbiRule
after, attach, before, embeddedPostgres, embeddedPostgres, externalPostgres, getHandle, getJdbi, h2, migrateWithFlyway, migrateWithFlyway, sqlite, withMigration, withPlugin, withPluginsModifier and TypeMethodDescriptionvoidafter()<T> TAttach an extension (such as a SqlObject) to the managed handle.voidbefore()static JdbiRuleCreate a JdbiRule with an embedded PostgreSQL instance.static JdbiRuleembeddedPostgres(Consumer<com.opentable.db.postgres.embedded.EmbeddedPostgres.Builder> customizer) Create a JdbiRule with an embedded PostgreSQL instance.static JdbiRuleCreate a JdbiRule using an external PostgreSQL instance.Get the single Handle instance opened for the duration of this test case.getJdbi()Get Jdbi, in case you want to open additional handles to the same data source.static JdbiRuleh2()Create a JdbiRule with an in-memory H2 database instance.Deprecated, for removal: This API element is subject to removal in a future version.migrateWithFlyway(String... locations) Deprecated, for removal: This API element is subject to removal in a future version.static JdbiRulesqlite()Create a JdbiRule with an in-memory Sqlite database instance.withMigration(Migration newMigration) Run database migration.withPlugin(JdbiPlugin plugin) Install a plugin into JdbiRule.Deprecated, for removal: This API element is subject to removal in a future version.Registering plugins implicitly is less reliable.Methods inherited from class org.junit.rules.ExternalResource
apply
-
Constructor Details
-
OracleDatabaseRule
-
-
Method Details
-
createTables
- Throws:
SQLException
-
JdbiRule.withMigration(Migration)