Assert.assertEquals("There should be 4 names left in the database (name is related to synonymName2)", 4, nNames);\r
int nRelations = service.countAllRelationships();\r
//may change with better implementation of countAllRelationships (see #2653)\r
- Assert.assertEquals("There should be 1 relationship left in the database (the name relationship)", 1, nRelations);\r
-\r
+ Assert.assertEquals("There should be 0 taxon relationships left in the database", 0, nRelations);\r
+ nRelations = nameService.getAllRelationships(1000, 0).size();\r
+ Assert.assertEquals("There should be 1 name relationship left in the database", 1, nRelations);\r
+ \r
+ \r
//clean up database\r
name2 = (TaxonNameBase)nameService.load(uuidSynonymName2);\r
NameRelationship rel = CdmBase.deproxy(name2.getNameRelations().iterator().next(), NameRelationship.class);\r
nNames = nameService.count(TaxonNameBase.class);\r
Assert.assertEquals("There should be 4 names left in the database", 4, nNames);\r
nRelations = service.countAllRelationships();\r
- //may change with better implementation of countAllRelationships (see #2653)\r
- Assert.assertEquals("There should be 1 name relationship and no synonym relationship in the database", 1, nRelations);\r
+ Assert.assertEquals("There should be no taxon or synonym relationship in the database", 0, nRelations);\r
+ nRelations = nameService.getAllRelationships(1000,0).size();\r
+ Assert.assertEquals("There should be 1 name relationship in the database", 1, nRelations);\r
\r
}\r
\r