upgrading to spring 4

This commit is contained in:
eugenp
2013-12-18 15:41:36 +02:00
parent 9bd7030906
commit df46e27e23
7 changed files with 9 additions and 9 deletions

View File

@@ -5,10 +5,10 @@ import static org.apache.commons.lang3.RandomStringUtils.randomAlphabetic;
import org.baeldung.persistence.model.Foo;
import org.baeldung.persistence.service.FooService;
import org.baeldung.spring.PersistenceConfig;
import org.hibernate.exception.DataException;
import org.junit.Test;
import org.junit.runner.RunWith;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.dao.DataAccessException;
import org.springframework.dao.DataIntegrityViolationException;
import org.springframework.dao.InvalidDataAccessApiUsageException;
import org.springframework.test.context.ContextConfiguration;
@@ -51,7 +51,7 @@ public class FooServicePersistenceIntegrationTest {
service.create(entity);
}
@Test(expected = DataException.class)
@Test(expected = DataAccessException.class)
public final void temp_whenInvalidEntityIsCreated_thenDataException() {
service.create(new Foo(randomAlphabetic(2048)));
}