示例#1
0
    def afterSetUp(self):
        """
        """
        super(TestStockInformationData, self).afterSetUp()
        container = self.shop["stock-information"]
        container.invokeFactory("StockInformation", id="s1")

        sm = IStockManagement(self.shop)
        self.si = sm.getStockInformationFor(self.shop.products.product_1)
 def testgetStockInformationFor_1(self):
     """
     """
     container = self.shop["stock-information"]
     container.invokeFactory("StockInformation", id="s1")
     
     sm = IStockManagement(self.shop)
     valid_stock_information = sm.getStockInformationFor(self.shop.products.product_1)
     
     self.assertEqual(valid_stock_information.getId(), "s1")
示例#3
0
    def testgetStockInformationFor_1(self):
        """
        """
        container = self.shop["stock-information"]
        container.invokeFactory("StockInformation", id="s1")

        sm = IStockManagement(self.shop)
        valid_stock_information = sm.getStockInformationFor(
            self.shop.products.product_1)

        self.assertEqual(valid_stock_information.getId(), "s1")