Ejemplo n.º 1
0
 def base_create_dep_objs(cls):
     """
     Create all objects that InstrumentGroup need.
     """
     groups = Groups()
     TestGroups.base_create_dep_objs()
     groups.from_hash(SAMPLE_GROUP_HASH)
     groups.save(force_insert=True)
     inst = Instruments()
     TestInstruments.base_create_dep_objs()
     inst.from_hash(SAMPLE_INSTRUMENT_HASH)
     inst.save(force_insert=True)
Ejemplo n.º 2
0
 def base_create_dep_objs(cls):
     """
     Create all objects that UserGroup need.
     """
     member = Users()
     TestUsers.base_create_dep_objs()
     member.from_hash(SAMPLE_USER_HASH)
     member.save(force_insert=True)
     groups = Groups()
     TestGroups.base_create_dep_objs()
     groups.from_hash(SAMPLE_GROUP_HASH)
     groups.save(force_insert=True)
Ejemplo n.º 3
0
 def dependent_cls(cls):
     """
     Return dependent classes for the InstrumentGroup object
     """
     ret = [InstrumentGroup]
     ret += TestInstruments.dependent_cls()
     ret += TestGroups.dependent_cls()
     return ret
Ejemplo n.º 4
0
 def dependent_cls(cls):
     """
     Return dependent classes for the UserGroup object
     """
     ret = [UserGroup]
     ret += TestUsers.dependent_cls()
     ret += TestGroups.dependent_cls()
     return ret