File tree 2 files changed +5
-4
lines changed
default-authorizationserver/src/test/java/sample
demo-authorizationserver/src/test/java/sample
2 files changed +5
-4
lines changed Original file line number Diff line number Diff line change 31
31
import org .springframework .beans .factory .annotation .Autowired ;
32
32
import org .springframework .boot .test .autoconfigure .web .servlet .AutoConfigureMockMvc ;
33
33
import org .springframework .boot .test .context .SpringBootTest ;
34
- import org .springframework .boot . test .mock . mockito .MockBean ;
34
+ import org .springframework .test .context . bean . override . mockito .MockitoBean ;
35
35
import org .springframework .http .HttpStatus ;
36
36
import org .springframework .security .oauth2 .server .authorization .OAuth2AuthorizationConsentService ;
37
37
import org .springframework .security .test .context .support .WithMockUser ;
38
+ import org .springframework .test .context .bean .override .mockito .MockitoBean ;
38
39
import org .springframework .test .context .junit .jupiter .SpringExtension ;
39
40
import org .springframework .web .util .UriComponentsBuilder ;
40
41
@@ -55,7 +56,7 @@ public class DefaultAuthorizationServerConsentTests {
55
56
@ Autowired
56
57
private WebClient webClient ;
57
58
58
- @ MockBean
59
+ @ MockitoBean
59
60
private OAuth2AuthorizationConsentService authorizationConsentService ;
60
61
61
62
private final String redirectUri = "http://127.0.0.1/login/oauth2/code/messaging-client-oidc" ;
Original file line number Diff line number Diff line change 31
31
import org .springframework .beans .factory .annotation .Autowired ;
32
32
import org .springframework .boot .test .autoconfigure .web .servlet .AutoConfigureMockMvc ;
33
33
import org .springframework .boot .test .context .SpringBootTest ;
34
- import org .springframework .boot . test .mock . mockito .MockBean ;
34
+ import org .springframework .test .context . bean . override . mockito .MockitoBean ;
35
35
import org .springframework .http .HttpStatus ;
36
36
import org .springframework .security .oauth2 .server .authorization .OAuth2AuthorizationConsentService ;
37
37
import org .springframework .security .test .context .support .WithMockUser ;
@@ -55,7 +55,7 @@ public class DemoAuthorizationServerConsentTests {
55
55
@ Autowired
56
56
private WebClient webClient ;
57
57
58
- @ MockBean
58
+ @ MockitoBean
59
59
private OAuth2AuthorizationConsentService authorizationConsentService ;
60
60
61
61
private final String redirectUri = "http://127.0.0.1/login/oauth2/code/messaging-client-oidc" ;
You can’t perform that action at this time.
0 commit comments