-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
#75 Create TestIronocConfiguration.java
- Loading branch information
1 parent
1cc4164
commit 21e1ffc
Showing
1 changed file
with
20 additions
and
0 deletions.
There are no files selected for viewing
20 changes: 20 additions & 0 deletions
20
src/test/java/com/ironoc/portfolio/config/TestIronocConfiguration.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
package com.ironoc.portfolio.config; | ||
|
||
import org.springframework.beans.BeansException; | ||
import org.springframework.boot.test.context.TestConfiguration; | ||
import org.springframework.context.ApplicationContext; | ||
import org.springframework.context.ApplicationContextAware; | ||
import org.springframework.context.annotation.ComponentScan; | ||
import org.springframework.web.servlet.config.annotation.WebMvcConfigurer; | ||
|
||
@TestConfiguration | ||
@ComponentScan(basePackages = { "com.ironoc.portfolio" }) | ||
public class TestIronocConfiguration implements WebMvcConfigurer, ApplicationContextAware { | ||
|
||
private ApplicationContext applicationContext; | ||
|
||
@Override | ||
public void setApplicationContext(ApplicationContext applicationContext) throws BeansException { | ||
this.applicationContext = applicationContext; | ||
} | ||
} |