def testGetTaxForCustomer(self):
        """
        """
        t = ITaxes(self.item1)
        tax = "%.2f" % t.getTaxForCustomer()
        self.assertEqual(tax, "7.03")

        t = ITaxes(self.item2)
        tax = "%.2f" % t.getTaxForCustomer()
        self.assertEqual(tax, "9.10")
    def testGetTaxForCustomer(self):
        """
        """
        t = ITaxes(self.item1)
        tax = "%.2f" % t.getTaxForCustomer()
        self.assertEqual(tax, "7.03")

        t = ITaxes(self.item2)
        tax = "%.2f" % t.getTaxForCustomer()
        self.assertEqual(tax, "9.10")
Beispiel #3
0
 def testGetTaxForCustomer_2(self):
     """With tax rate for customer
     """
     self.shop.taxes.invokeFactory("CustomerTax", id="customer", rate=10.0)
     tm = ITaxes(self.shop)
     tax = tm.getTaxForCustomer(self.product_1)
     self.assertEqual("%.2f" % tax, "1.85")
 def testGetTaxForCustomer_2(self):
     """With tax rate for customer
     """
     self.shop.taxes.invokeFactory("CustomerTax", id="customer", rate=10.0)        
     tm = ITaxes(self.shop)
     tax = tm.getTaxForCustomer(self.product_1)
     self.assertEqual("%.2f" % tax, "1.85")
Beispiel #5
0
 def testGetTaxForCustomer_1(self):
     """Without tax rate for customer
     """
     tm = ITaxes(self.shop)
     tax = tm.getTaxForCustomer(self.product_1)
     self.assertEqual("%.2f" % tax, "3.51")
 def testGetTaxForCustomer(self):
     """
     """
     t = ITaxes(self.shop.products.product_1)
     self.assertEqual("%.2f" % t.getTaxForCustomer(), "1.85")
Beispiel #7
0
 def testGetTaxForCustomer(self):
     """
     """
     t = ITaxes(self.cart)
     tax = "%.2f" % t.getTaxForCustomer()
     self.assertEqual(tax, "16.13")
 def testGetTaxForCustomer_1(self):
     """Without tax rate for customer
     """
     tm = ITaxes(self.shop)
     tax = tm.getTaxForCustomer(self.product_1)
     self.assertEqual("%.2f" % tax, "3.51")
 def testGetTaxForCustomer(self):
     """
     """
     t = ITaxes(self.shop.products.product_1)
     self.assertEqual("%.2f" % t.getTaxForCustomer(), "1.85")