change expect exception in ut
This commit is contained in:
parent
77240dc024
commit
e84957c768
|
@ -1,15 +1,16 @@
|
|||
package com.baeldung.factorybean;
|
||||
|
||||
import org.junit.Test;
|
||||
import org.springframework.beans.factory.BeanCreationException;
|
||||
import org.springframework.context.support.ClassPathXmlApplicationContext;
|
||||
|
||||
public class FactoryBeanInitializeTest {
|
||||
@Test(expected = Exception.class)
|
||||
@Test(expected = BeanCreationException.class)
|
||||
public void testInitializationToolFactory() {
|
||||
new ClassPathXmlApplicationContext("classpath:factorybean-init-spring-ctx.xml");
|
||||
}
|
||||
|
||||
@Test(expected = Exception.class)
|
||||
@Test(expected = BeanCreationException.class)
|
||||
public void testPostConstructToolFactory() {
|
||||
new ClassPathXmlApplicationContext("classpath:factorybean-postconstruct-spring-ctx.xml");
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue