def setUp(self): activateAndReindex(self.layer["portal"]) commit() self.browser = Browser(self.layer["app"]) self.browser.addHeader( "Authorization", "Basic %s:%s" % (SITE_OWNER_NAME, SITE_OWNER_PASSWORD))
def setUp(self): self.portal = self.layer["portal"] self.request = self.layer["request"] activateAndReindex(self.portal) response = self.request.RESPONSE self.write = response.write response.write = lambda x: x # temporarily ignore output self.maintenance = self.portal.unrestrictedTraverse("solr-maintenance")
def setUp(self): self.portal = self.layer['portal'] self.request = self.layer['request'] activateAndReindex(self.portal) response = self.request.RESPONSE self.write = response.write response.write = lambda x: x # temporarily ignore output self.maintenance = self.portal.unrestrictedTraverse('solr-maintenance')
def setUp(self): activateAndReindex(self.layer['portal']) commit() self.browser = Browser(self.layer['app']) self.browser.addHeader( 'Authorization', 'Basic %s:%s' % (SITE_OWNER_NAME, SITE_OWNER_PASSWORD,) )
def setUp(self): self.portal = self.layer['portal'] activateAndReindex(self.portal) setRoles(self.portal, TEST_USER_ID, ['Manager']) fti = DexterityFTI('My Dexterity Container') self.portal.portal_types._setObject('My Dexterity Container', fti) fti.klass = 'plone.dexterity.content.Container' fti.schema = 'zope.interface.Interface' fti.behaviors = ('collective.solr.behaviors.ISolrFields', ) self.portal.invokeFactory('My Dexterity Container', 'child') self.child = self.portal['child']
def setUp(self): self.portal = self.layer['portal'] activateAndReindex(self.portal) setRoles(self.portal, TEST_USER_ID, ['Manager']) fti = DexterityFTI('My Dexterity Container') self.portal.portal_types._setObject('My Dexterity Container', fti) fti.klass = 'plone.dexterity.content.Container' fti.schema = 'zope.interface.Interface' fti.behaviors = ('collective.solr.behaviors.ISolrFields',) self.portal.invokeFactory('My Dexterity Container', 'child') self.child = self.portal['child']
def setUp(self): self.portal = self.layer["portal"] activateAndReindex(self.portal) setRoles(self.portal, TEST_USER_ID, ["Manager"]) fti = DexterityFTI("My Dexterity Container") self.portal.portal_types._setObject("My Dexterity Container", fti) fti.klass = "plone.dexterity.content.Container" fti.schema = "zope.interface.Interface" fti.behaviors = ("collective.solr.behaviors.ISolrFields", ) self.portal.invokeFactory("My Dexterity Container", "child") self.child = self.portal["child"]
def setUp(self): portal = self.portal = self.layer['portal'] setRoles(self.portal, TEST_USER_ID, ['Manager']) id_ = portal.invokeFactory('Collection', id='foo', title='Foo') collection = self.collection = portal[id_] self.query = query = [{ 'i': 'SearchableText', 'o': 'plone.app.querystring.operation.string.contains', 'v': 'new' }] collection.query = query activateAndReindex(portal)
def setUp(self): portal = self.portal = self.layer["portal"] setRoles(self.portal, TEST_USER_ID, ["Manager"]) id_ = portal.invokeFactory("Collection", id="foo", title="Foo") collection = self.collection = portal[id_] self.query = query = [{ "i": "SearchableText", "o": "plone.app.querystring.operation.string.contains", "v": "new", }] collection.query = query activateAndReindex(portal)
def setUp(self): portal = self.portal = self.layer['portal'] setRoles(self.portal, TEST_USER_ID, ['Manager']) id_ = portal.invokeFactory('Collection', id='foo', title='Foo') collection = self.collection = portal[id_] self.query = query = [ {'i': 'SearchableText', 'o': 'plone.app.querystring.operation.string.contains', 'v': 'new'} ] collection.query = query activateAndReindex(portal)
def setUp(self): self.portal = self.layer["portal"] self.request = self.layer["request"] self._setUpGeolocationCatalogIndex() self._setUpLocationType() setRoles(self.portal, TEST_USER_ID, ("Manager", )) self.config = getConfig() self.config.required = [] self.maintenance = self.portal.unrestrictedTraverse("solr-maintenance") commit() self.response = self.request.RESPONSE self.write = self.response.write self.response.write = lambda x: x # temporarily ignore output activateAndReindex(self.portal)