Add rest-client-test module: @RestClientTest on Boot 4.1, Jackson 3 by default, and the RestClient-vs-RestTemplate root-URI matching trap (post #49)
This commit is contained in:
@@ -0,0 +1,12 @@
|
||||
package com.ankurm.restclienttest;
|
||||
|
||||
/**
|
||||
* A collaborator {@code EmployeeClient} depends on but that has nothing to do with REST clients
|
||||
* itself. {@code @RestClientTest}'s minimal context never creates a bean for this on its own -
|
||||
* it exists specifically so the test class can demonstrate replacing it with
|
||||
* {@code @MockitoBean}, now that {@code @MockBean} is gone in Spring Boot 4.
|
||||
*/
|
||||
public interface EmployeeAuditLogger {
|
||||
|
||||
void logFetch(Integer employeeId);
|
||||
}
|
||||
Reference in New Issue
Block a user