Skip to content

Commit

Permalink
Fix tests for Flyway to generate correct reflection metadata
Browse files Browse the repository at this point in the history
  • Loading branch information
mhalbritter committed Nov 4, 2024
1 parent fe9ad03 commit 37c6263
Show file tree
Hide file tree
Showing 3 changed files with 45 additions and 2 deletions.
39 changes: 39 additions & 0 deletions metadata/org.flywaydb/flyway-core/10.20.0/reflect-config.json
Original file line number Diff line number Diff line change
Expand Up @@ -146,6 +146,45 @@
}
]
},
{
"name": "org.flywaydb.core.internal.logging.apachecommons.ApacheCommonsLogCreator",
"condition": {
"typeReachable": "org.flywaydb.core.internal.util.ClassUtils"
},
"methods": [
{
"name": "<init>",
"parameterTypes": [
]
}
]
},
{
"name": "org.flywaydb.core.internal.logging.log4j2.Log4j2LogCreator",
"condition": {
"typeReachable": "org.flywaydb.core.internal.util.ClassUtils"
},
"methods": [
{
"name": "<init>",
"parameterTypes": [
]
}
]
},
{
"name": "org.flywaydb.core.internal.logging.slf4j.Slf4jLogCreator",
"condition": {
"typeReachable": "org.flywaydb.core.internal.util.ClassUtils"
},
"methods": [
{
"name": "<init>",
"parameterTypes": [
]
}
]
},
{
"name": "org.flywaydb.core.internal.proprietaryStubs.LicensingConfigurationExtensionStub",
"condition": {
Expand Down
5 changes: 4 additions & 1 deletion tests/src/org.flywaydb/flyway-core/10.20.0/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -12,9 +12,12 @@ String libraryVersion = tck.testedLibraryVersion.get()

dependencies {
testImplementation "org.flywaydb:flyway-core:$libraryVersion"
testImplementation 'com.h2database:h2:2.1.210'
testImplementation 'com.h2database:h2:2.2.224'
testImplementation 'org.assertj:assertj-core:3.22.0'
testImplementation 'org.awaitility:awaitility:4.2.0'
testRuntimeOnly 'org.slf4j:slf4j-simple:2.0.16'
testRuntimeOnly 'org.apache.logging.log4j:log4j-api:2.24.1'
testRuntimeOnly 'commons-logging:commons-logging:1.3.4'
}

graalvmNative {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,8 @@ void migrate() {
Configuration configuration = new FluentConfiguration()
.dataSource(dataSource)
.encoding(StandardCharsets.UTF_8)
.resourceProvider(new FixedResourceProvider());
.resourceProvider(new FixedResourceProvider())
.loggers("slf4j", "log4j2", "apache-commons");

Flyway flyway = new Flyway(configuration);
MigrateResult migration = flyway.migrate();
Expand Down

0 comments on commit 37c6263

Please sign in to comment.