-
Notifications
You must be signed in to change notification settings - Fork 519
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Spring @WebMvcTest stopped working with ShedLock 6.0.1 #2272
Comments
Thanks, I will look into that. There were some changes in this area (that's actually the reason for the major release) |
As a workaround you can move the The behavior indeed changed in 6.0.1. I like the new behavior better - to fail on startup if LockProvider is missing, but I prefer maintianing backward compatiblility more, so I will most likely revert it to the original behavior #2274. Thanks again for reporting |
#2272 Do not fail in startup time if LockProvider is not found
Released in 6.0.2 |
Since version 6.0.1, Spring @WebMvcTest stopped working with the following error message
According to documentation, @WebMvcTest
only enables auto-configuration that is relevant to MVC tests
, which is why our LockProvider Bean cannot be found.However, it should not be needed in the first place (as it was in 5.x.x), and providing it via
@Import(SchedlockConfig.class)
is no viable solution because that requires a DataSource bean which is exactly what a @WebMvcTest should not need.our configuration:
Our application is annotated with
@EnableSchedulerLock(interceptMode = PROXY_METHOD)
The text was updated successfully, but these errors were encountered: