예제 #1
0
    def setUp(self):
        self.portal = self.layer['portal']
        self.request = self.layer['request']
        set_browserlayer(self.request)

        # setup mocks
        alsoProvides(self.portal, ICartItem)
        provideAdapter(MockCartItemDataProvider)
예제 #2
0
    def setUp(self):
        self.portal = self.layer['portal']
        self.request = self.layer['request']
        set_browserlayer(self.request)

        # setup mocks
        alsoProvides(self.portal, ICartItem)
        provideAdapter(MockCartItemDataProvider)
예제 #3
0
    def setUp(self):
        self.portal = self.layer['portal']
        self.request = self.layer['request']
        set_browserlayer(self.request)

        # create an object for testing
        setRoles(self.portal, TEST_USER_ID, ['Manager'])
        login(self.portal, TEST_USER_NAME)
        self.portal.invokeFactory('Document', 'doc')
        self.doc = self.portal['doc']
예제 #4
0
    def setUp(self):
        self.portal = self.layer['portal']
        self.request = self.layer['request']
        set_browserlayer(self.request)

        # create an object for testing
        setRoles(self.portal, TEST_USER_ID, ['Manager'])
        login(self.portal, TEST_USER_NAME)
        self.portal.invokeFactory('Document', 'doc')
        self.doc = self.portal['doc']
예제 #5
0
    def setUp(self):
        self.portal = self.layer['portal']
        self.request = self.layer['request']
        set_browserlayer(self.request)

        # setup mocks
        alsoProvides(self.portal, ICartItem)
        provideAdapter(MockShipping, name='mock_shipping')
        provideAdapter(MockCartDataProvider)
        provideAdapter(MockCartItemState)
        self.cart_data_provider = getMultiAdapter(
            (self.portal, self.request), interface=ICartDataProvider)
        self.cart_item_state = getMultiAdapter(
            (self.portal, self.request), interface=ICartItemState)
예제 #6
0
    def setUp(self):
        self.portal = self.layer['portal']
        self.request = self.layer['request']
        set_browserlayer(self.request)

        # setup mocks
        alsoProvides(self.portal, ICartItem)
        provideAdapter(MockShipping, name='mock_shipping')
        provideAdapter(MockCartDataProvider)
        provideAdapter(MockCartItemDataProvider)
        provideAdapter(MockCartItemState)
        self.cart_data_provider = getMultiAdapter(
            (self.portal, self.request), interface=ICartDataProvider)
        self.cart_item_state = getMultiAdapter(
            (self.portal, self.request), interface=ICartItemState)
예제 #7
0
 def setUp(self):
     self.portal = self.layer['portal']
     self.request = self.layer['request']
     set_browserlayer(self.request)
예제 #8
0
 def setUp(self):
     self.portal = self.layer['portal']
     self.request = self.layer['request']
     set_browserlayer(self.request)