Skip to content

Commit

Permalink
SHIBUI-2003
Browse files Browse the repository at this point in the history
Adjusting hibernate properties to enforce not-null declaration
  • Loading branch information
chasegawa committed Aug 8, 2021
1 parent 4a8cfe6 commit d43407e
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion backend/src/main/resources/application.properties
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ spring.jpa.hibernate.ddl-auto=update
spring.jpa.hibernate.naming.implicit-strategy=org.hibernate.boot.model.naming.ImplicitNamingStrategyJpaCompliantImpl
spring.jpa.show-sql=false
spring.jpa.properties.hibernate.format_sql=false

spring.jpa.properties.hibernate.check_nullability=true
spring.jpa.hibernate.use-new-id-generator-mappings=true

#Envers versioning
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -85,7 +85,7 @@ class CustomEntityAttributeDefinitionRepositoryTests extends Specification {

then:
// Missing non-nullable field should thrown error
final def exception = thrown(javax.persistence.PersistenceException)
final def exception = thrown(org.springframework.dao.DataIntegrityViolationException)
}

def "basic CRUD operations validated"() {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -82,7 +82,7 @@ class GroupsRepositoryTests extends Specification {

then:
// Missing non-nullable field (name) should thrown error
final def exception = thrown(javax.persistence.PersistenceException)
final def exception = thrown(org.springframework.dao.DataIntegrityViolationException)
}

def "basic CRUD operations validated"() {
Expand Down

0 comments on commit d43407e

Please sign in to comment.