server/repository.py
changeset 3409 c684606a95e0
parent 3381 9ddc8937e16d
child 3424 60c9722a590b
equal deleted inserted replaced
3408:c92170fca813 3409:c684606a95e0
   186             config.bootstrap_cubes()
   186             config.bootstrap_cubes()
   187             self.set_schema(config.load_schema(), resetvreg=False)
   187             self.set_schema(config.load_schema(), resetvreg=False)
   188             # need to load the Any and CWUser entity types
   188             # need to load the Any and CWUser entity types
   189             etdirectory = join(CW_SOFTWARE_ROOT, 'entities')
   189             etdirectory = join(CW_SOFTWARE_ROOT, 'entities')
   190             self.vreg.init_registration([etdirectory])
   190             self.vreg.init_registration([etdirectory])
   191             self.vreg.load_file(join(etdirectory, '__init__.py'),
   191             for modname in ('__init__', 'authobjs', 'wfobjs'):
   192                                 'cubicweb.entities.__init__')
   192                 self.vreg.load_file(join(etdirectory, '%s.py' % modname),
   193             self.vreg.load_file(join(etdirectory, 'authobjs.py'),
   193                                 'cubicweb.entities.%s' % modname)
   194                                 'cubicweb.entities.authobjs')
   194             hooksdirectory = join(CW_SOFTWARE_ROOT, 'hooks')
   195             self.vreg.load_file(join(etdirectory, 'wfobjs.py'),
   195             self.vreg.init_registration([hooksdirectory])
   196                                 'cubicweb.entities.wfobjs')
   196             self.vreg.load_file(join(hooksdirectory, 'metadata.py'),
       
   197                                 'cubicweb.hooks.metadata')
   197         else:
   198         else:
   198             # test start: use the file system schema (quicker)
   199             # test start: use the file system schema (quicker)
   199             self.warning("set fs instance'schema")
   200             self.warning("set fs instance'schema")
   200             config.bootstrap_cubes()
   201             config.bootstrap_cubes()
   201             self.set_schema(config.load_schema())
   202             self.set_schema(config.load_schema())