server/__init__.py
branchstable
changeset 3699 20ba545e00e1
parent 3530 7dfe9d2c0fe7
child 3720 5376aaadd16b
child 3823 94aa250cff9b
equal deleted inserted replaced
3694:33dbb1da1db9 3699:20ba545e00e1
   174     session.execute('SET U in_group G WHERE G name "managers"')
   174     session.execute('SET U in_group G WHERE G name "managers"')
   175     session.commit()
   175     session.commit()
   176     # reloging using the admin user
   176     # reloging using the admin user
   177     config._cubes = None # avoid assertion error
   177     config._cubes = None # avoid assertion error
   178     repo, cnx = in_memory_cnx(config, login, pwd)
   178     repo, cnx = in_memory_cnx(config, login, pwd)
       
   179     # trigger vreg initialisation of entity classes
       
   180     config.cubicweb_appobject_path = set(('entities',))
       
   181     config.cube_appobject_path = set(('entities',))
       
   182     repo.vreg.set_schema(repo.schema)
   179     assert len(repo.sources) == 1, repo.sources
   183     assert len(repo.sources) == 1, repo.sources
   180     handler = config.migration_handler(schema, interactive=False,
   184     handler = config.migration_handler(schema, interactive=False,
   181                                        cnx=cnx, repo=repo)
   185                                        cnx=cnx, repo=repo)
   182     initialize_schema(config, schema, handler)
   186     initialize_schema(config, schema, handler)
   183     # yoo !
   187     # yoo !