Skip to content

Commit 0515330

Browse files
mhalbritterfniephaus
authored andcommitted
Fix tests for Flyway to generate correct reflection metadata
1 parent fe9ad03 commit 0515330

File tree

3 files changed

+45
-2
lines changed

3 files changed

+45
-2
lines changed

metadata/org.flywaydb/flyway-core/10.20.0/reflect-config.json

Lines changed: 39 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -146,6 +146,45 @@
146146
}
147147
]
148148
},
149+
{
150+
"name": "org.flywaydb.core.internal.logging.apachecommons.ApacheCommonsLogCreator",
151+
"condition": {
152+
"typeReachable": "org.flywaydb.core.internal.util.ClassUtils"
153+
},
154+
"methods": [
155+
{
156+
"name": "<init>",
157+
"parameterTypes": [
158+
]
159+
}
160+
]
161+
},
162+
{
163+
"name": "org.flywaydb.core.internal.logging.log4j2.Log4j2LogCreator",
164+
"condition": {
165+
"typeReachable": "org.flywaydb.core.internal.util.ClassUtils"
166+
},
167+
"methods": [
168+
{
169+
"name": "<init>",
170+
"parameterTypes": [
171+
]
172+
}
173+
]
174+
},
175+
{
176+
"name": "org.flywaydb.core.internal.logging.slf4j.Slf4jLogCreator",
177+
"condition": {
178+
"typeReachable": "org.flywaydb.core.internal.util.ClassUtils"
179+
},
180+
"methods": [
181+
{
182+
"name": "<init>",
183+
"parameterTypes": [
184+
]
185+
}
186+
]
187+
},
149188
{
150189
"name": "org.flywaydb.core.internal.proprietaryStubs.LicensingConfigurationExtensionStub",
151190
"condition": {

tests/src/org.flywaydb/flyway-core/10.20.0/build.gradle

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,9 +12,12 @@ String libraryVersion = tck.testedLibraryVersion.get()
1212

1313
dependencies {
1414
testImplementation "org.flywaydb:flyway-core:$libraryVersion"
15-
testImplementation 'com.h2database:h2:2.1.210'
15+
testImplementation 'com.h2database:h2:2.2.224'
1616
testImplementation 'org.assertj:assertj-core:3.22.0'
1717
testImplementation 'org.awaitility:awaitility:4.2.0'
18+
testRuntimeOnly 'org.slf4j:slf4j-simple:2.0.16'
19+
testRuntimeOnly 'org.apache.logging.log4j:log4j-api:2.24.1'
20+
testRuntimeOnly 'commons-logging:commons-logging:1.3.4'
1821
}
1922

2023
graalvmNative {

tests/src/org.flywaydb/flyway-core/10.20.0/src/test/java/flyway/FlywayTests.java

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,8 @@ void migrate() {
2828
Configuration configuration = new FluentConfiguration()
2929
.dataSource(dataSource)
3030
.encoding(StandardCharsets.UTF_8)
31-
.resourceProvider(new FixedResourceProvider());
31+
.resourceProvider(new FixedResourceProvider())
32+
.loggers("slf4j", "log4j2", "apache-commons");
3233

3334
Flyway flyway = new Flyway(configuration);
3435
MigrateResult migration = flyway.migrate();

0 commit comments

Comments
 (0)