equal
deleted
inserted
replaced
240 self.assertIsInstance(ex.entity, int) |
240 self.assertIsInstance(ex.entity, int) |
241 self.assertEquals(ex.errors, {'login': 'the value "admin" is already used, use another one'}) |
241 self.assertEquals(ex.errors, {'login': 'the value "admin" is already used, use another one'}) |
242 |
242 |
243 |
243 |
244 class SchemaModificationHooksTC(RepositoryBasedTC): |
244 class SchemaModificationHooksTC(RepositoryBasedTC): |
245 copy_schema = True |
245 #copy_schema = True |
246 |
246 |
247 def setUp(self): |
247 def setUp(self): |
248 if not hasattr(self, '_repo'): |
248 if not hasattr(self, '_repo'): |
249 # first initialization |
249 # first initialization |
250 repo = self.repo # set by the RepositoryBasedTC metaclass |
250 repo = self.repo # set by the RepositoryBasedTC metaclass |
469 'WHERE DEF relation_type RT, DEF from_entity E,' |
469 'WHERE DEF relation_type RT, DEF from_entity E,' |
470 'RT name "prenom", E name "Personne"') |
470 'RT name "prenom", E name "Personne"') |
471 self.commit() |
471 self.commit() |
472 # should not be able anymore to add personne without prenom |
472 # should not be able anymore to add personne without prenom |
473 self.assertRaises(ValidationError, self.execute, 'INSERT Personne X: X nom "toto"') |
473 self.assertRaises(ValidationError, self.execute, 'INSERT Personne X: X nom "toto"') |
|
474 self.execute('SET DEF cardinality "?1" ' |
|
475 'WHERE DEF relation_type RT, DEF from_entity E,' |
|
476 'RT name "prenom", E name "Personne"') |
|
477 self.commit() |
474 |
478 |
475 |
479 |
476 class WorkflowHooksTC(RepositoryBasedTC): |
480 class WorkflowHooksTC(RepositoryBasedTC): |
477 |
481 |
478 def setUp(self): |
482 def setUp(self): |