maven work
This commit is contained in:
@@ -0,0 +1,17 @@
|
||||
package com.baeldung;
|
||||
|
||||
import org.mockito.Mockito;
|
||||
import org.springframework.context.annotation.Bean;
|
||||
import org.springframework.context.annotation.Configuration;
|
||||
import org.springframework.context.annotation.Primary;
|
||||
import org.springframework.context.annotation.Profile;
|
||||
|
||||
@Profile("test")
|
||||
@Configuration
|
||||
public class NameServiceTestConfiguration {
|
||||
@Bean
|
||||
@Primary
|
||||
public NameService nameService() {
|
||||
return Mockito.mock(NameService.class);
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user