Beispiel #1
0
class StandardPlanChangePolicyTestCase(TestCase):
    fixtures = ['initial_plan',
                'test_django-plans_auth', 'test_django-plans_plans']

    def setUp(self):
        self.policy = StandardPlanChangePolicy()

    def test_get_change_price(self):
        p1 = Plan.objects.get(pk=3)
        p2 = Plan.objects.get(pk=4)
        self.assertEqual(self.policy.get_change_price(p1, p2, 23),
                         Decimal('8.60'))
        self.assertEqual(self.policy.get_change_price(p2, p1, 23), None)
Beispiel #2
0
 def setUp(self):
     self.policy = StandardPlanChangePolicy()
Beispiel #3
0
 def setUp(self):
     self.policy = StandardPlanChangePolicy()