relationship « Test « JPA Q&A





1. how to make test fail for one-to-one relationship in grails?    stackoverflow.com

I want to make one-to-one relationship in grails and to TEST it. So i created two classes. There are two classes below.


class Book {

  String title
  Date ...

2. Can't get Many to Many relationship persistence tests to pass at the same time in Grails 1.3.7    stackoverflow.com

I have two integration tests inside my Grails 1.3.7 application:

  • testAddAssociateShiroUserCompanyRefWithExistingCompany
  • testAddAssociateShiroUserCompanyRefWithExistingCompany
both of these tests call CompanyService.addNewCompanyWithShiroUserCompanyRef to associate a ManyToMany relationship between Company and User. Company extends from a base class ...