def set_up(self): FunctionalTestCase.set_up(self) self.config.load_zcml( 'everest.tests.complete_app:configure_no_rdb.zcml') self.config.add_view(context=get_collection_class(IMyEntity), view=ExceptionPostCollectionView, request_method=RequestMethods.POST)
def set_up(self): FunctionalTestCase.set_up(self) self.config.load_zcml( 'everest.tests.complete_app:configure_no_rdb.zcml') self.config.add_view(context=get_collection_class(IMyEntity), view=ExceptionPostCollectionView, request_method='POST')
def set_up(self): FunctionalTestCase.set_up(self) self.config.load_zcml('everest.tests.complete_app:configure_rpr.zcml') self.config.add_renderer('csv', RendererFactory) self.config.add_view(context=get_collection_class(IMyEntity), view=GetCollectionView, renderer='csv', request_method=RequestMethods.GET, custom_predicates=(accept_csv_only,))
def set_up(self): FunctionalTestCase.set_up(self) self.config.load_zcml('everest.tests.complete_app:configure_no_rdb.zcml') self.config.add_view(context=IService, view=public_view, name='public', request_method='GET') fn = resource_filename('everest.tests.complete_app', 'data/original') self.config.registry.settings['public_dir'] = fn
def set_up(self): FunctionalTestCase.set_up(self) self.config.load_zcml('everest.tests.complete_app:configure_rpr.zcml') self.config.add_renderer('csv', RendererFactory) self.config.add_view(context=get_collection_class(IMyEntity), view=GetCollectionView, renderer='csv', request_method='GET', custom_predicates=(accept_csv_only,))
def set_up(self): FunctionalTestCase.set_up(self) self.config.load_zcml( 'everest.tests.complete_app:configure_no_rdb.zcml') self.config.add_member_view(IMyEntity, view=ExceptionPutMemberView, request_method=RequestMethods.PUT) self.config.add_collection_view(IMyEntity, view=ExceptionPostCollectionView, request_method=RequestMethods.POST)
def set_up(self): FunctionalTestCase.set_up(self) self.config.load_zcml( 'everest.tests.complete_app:configure_no_rdb.zcml') self.config.add_member_view(IMyEntity, view=ExceptionPutMemberView, request_method='PUT') self.config.add_collection_view(IMyEntity, view=ExceptionPostCollectionView, request_method='POST')
def set_up(self): FunctionalTestCase.set_up(self) self.config.load_zcml(self.config_file_name) # We have to call this again to initialize the newly created SYSTEM # repo. repo_mgr = get_repository_manager() repo_mgr.initialize_all() self.config.add_collection_view(FooCollection, view=UserMessagePostCollectionView, request_method=RequestMethods.POST) self.config.add_member_view(FooMember, view=UserMessagePutMemberView, request_method=RequestMethods.PUT)
def set_up(self): FunctionalTestCase.set_up(self) self.config.load_zcml(self.config_file_name) # We have to call this again to initialize the newly created SYSTEM # repo. repo_mgr = get_repository_manager() repo_mgr.initialize_all() self.config.add_collection_view(FooCollection, view=UserMessagePostCollectionView, request_method='POST') self.config.add_member_view(FooMember, view=UserMessagePutMemberView, request_method='PUT')
def set_up(self): FunctionalTestCase.set_up(self) self.config.load_zcml('everest.tests.complete_app:configure_rpr.zcml') self.config.add_resource_view(IMyEntity, renderer='csv', request_method='GET') self.config.add_member_view(IMyEntity, renderer='csv', request_method='PUT') self.config.add_collection_view(IMyEntity, renderer='csv', request_method='POST') self.config.add_collection_view(IMyEntityChild, renderer='csv', request_method='POST') self.config.add_member_view(IMyEntity, renderer='csv', request_method='DELETE')
def tear_down(self): transaction.abort() Session.remove() FunctionalTestCase.tear_down(self)
def set_up(self): FunctionalTestCase.set_up(self)
def set_up(self): FunctionalTestCase.set_up(self) self.config.load_zcml(self.views_config_file_name) coll = get_root_collection(IFoo) coll.create_member(FooEntity(id=0)) transaction.commit()