16
16
package org .springframework .data .web .aot ;
17
17
18
18
import static org .assertj .core .api .Assertions .*;
19
+ import static org .mockito .Mockito .*;
19
20
20
21
import org .junit .jupiter .api .Test ;
21
- import org . mockito . Mockito ;
22
+
22
23
import org .springframework .aot .hint .ReflectionHints ;
23
24
import org .springframework .aot .hint .RuntimeHints ;
24
25
import org .springframework .aot .hint .TypeReference ;
25
26
import org .springframework .aot .hint .predicate .RuntimeHintsPredicates ;
26
27
import org .springframework .data .test .util .ClassPathExclusions ;
27
28
28
29
/**
30
+ * Unit tests for {@link WebRuntimeHints}.
31
+ *
29
32
* @author Christoph Strobl
30
33
*/
31
34
class WebRuntimeHintsUnitTests {
@@ -34,8 +37,8 @@ class WebRuntimeHintsUnitTests {
34
37
void shouldRegisterRuntimeHintWhenJacksonPresent () {
35
38
36
39
ReflectionHints reflectionHints = new ReflectionHints ();
37
- RuntimeHints runtimeHints = Mockito . mock (RuntimeHints .class );
38
- Mockito . when (runtimeHints .reflection ()).thenReturn (reflectionHints );
40
+ RuntimeHints runtimeHints = mock (RuntimeHints .class );
41
+ when (runtimeHints .reflection ()).thenReturn (reflectionHints );
39
42
40
43
new WebRuntimeHints ().registerHints (runtimeHints , this .getClass ().getClassLoader ());
41
44
@@ -48,8 +51,8 @@ void shouldRegisterRuntimeHintWhenJacksonPresent() {
48
51
void shouldRegisterRuntimeHintWithTypeNameWhenJacksonNotPresent () {
49
52
50
53
ReflectionHints reflectionHints = new ReflectionHints ();
51
- RuntimeHints runtimeHints = Mockito . mock (RuntimeHints .class );
52
- Mockito . when (runtimeHints .reflection ()).thenReturn (reflectionHints );
54
+ RuntimeHints runtimeHints = mock (RuntimeHints .class );
55
+ when (runtimeHints .reflection ()).thenReturn (reflectionHints );
53
56
54
57
new WebRuntimeHints ().registerHints (runtimeHints , this .getClass ().getClassLoader ());
55
58
0 commit comments