Skip to content

OptimizedFlywayTestExecutionListener.resolveMigrations fails with a NullPointerException when debug logging is enabled on org.springframework.test.util.ReflectionTestUtils #70

@tomix26

Description

@tomix26
java.lang.NullPointerException
	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
	at java.lang.reflect.Method.invoke(Method.java:498)
	at org.springframework.aop.support.AopUtils.invokeJoinpointUsingReflection(AopUtils.java:343)
	at org.springframework.aop.framework.ReflectiveMethodInvocation.invokeJoinpoint(ReflectiveMethodInvocation.java:198)
	at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:163)
	at io.zonky.test.db.flyway.OptimizedFlywayTestExecutionListener.lambda$resolveMigrations$3(OptimizedFlywayTestExecutionListener.java:245)
	at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:186)
	at org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:212)
	at com.sun.proxy.$Proxy295.toString(Unknown Source)
	at java.lang.String.valueOf(String.java:2994)
	at org.springframework.util.ObjectUtils.nullSafeToString(ObjectUtils.java:720)
	at org.springframework.test.util.ReflectionTestUtils.invokeMethod(ReflectionTestUtils.java:434)
	at io.zonky.test.db.flyway.OptimizedFlywayTestExecutionListener.resolveMigrations(OptimizedFlywayTestExecutionListener.java:246)
	at io.zonky.test.db.flyway.OptimizedFlywayTestExecutionListener.findFirstVersion(OptimizedFlywayTestExecutionListener.java:221)
	at io.zonky.test.db.flyway.OptimizedFlywayTestExecutionListener.isAppendable(OptimizedFlywayTestExecutionListener.java:211)
	at io.zonky.test.db.flyway.OptimizedFlywayTestExecutionListener.reloadDataSource(OptimizedFlywayTestExecutionListener.java:182)
	at io.zonky.test.db.flyway.OptimizedFlywayTestExecutionListener.optimizedDbReset(OptimizedFlywayTestExecutionListener.java:148)
	at io.zonky.test.flyway.ConditionalFlywayTestExecutionListener.optimizedDbReset(ConditionalFlywayTestExecutionListener.java:17)
	at io.zonky.test.db.flyway.OptimizedFlywayTestExecutionListener.beforeTestMethod(OptimizedFlywayTestExecutionListener.java:114)
	at org.springframework.test.context.TestContextManager.beforeTestMethod(TestContextManager.java:291)

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions