@@ -0,0 +1,1770 @@
+# -*- coding: utf-8 -*-%0Afrom django.core.urlresolvers import reverse%0Afrom django.db.models import get_model%0Afrom oscar.test.factories import create_product%0Afrom oscar.test.testcases import ClientTestCase%0A%0AWishList = get_model('wishlists', 'WishList')%0A%0A%0Aclass TestWishlists(ClientTestCase):%0A%0A    def setUp(self):%0A        super(TestWishlists, self).setUp()%0A        self.product = create_product()%0A%0A    def test_add_to_wishlist_button_is_displayed(self):%0A        resp = self.client.get(self.product.get_absolute_url())%0A        self.assertContains(resp, reverse('customer:wishlists-create',%0A                                          args=%5Bself.product.pk%5D))%0A%0A    def test_add_a_product_to_wishlist(self):%0A        resp = self.client.get(reverse('customer:wishlists-create',%0A                                       args=%5Bself.product.pk%5D))%0A        self.assertIsOk(resp)%0A        self.assertEqual(WishList.objects.count(), 0)%0A        self.assertEqual(self.product.wishlists_lines.count(), 0)%0A        # not done here, need to submit the wishlist%0A        # and verify it can be deleted%0A        data = %7B'name': 'Shopping list for Santa Claus'%7D%0A        resp = self.client.post(reverse('customer:wishlists-create',%0A                                        args=%5Bself.product.pk%5D), data)%0A        self.assertIsRedirect(resp)%0A        self.assertEqual(WishList.objects.count(), 1)%0A        self.assertEqual(self.product.wishlists_lines.count(), 1)%0A        wishlist = WishList.objects.all()%5B0%5D%0A        resp = self.client.post(reverse('customer:wishlists-delete',%0A                                        args=%5Bwishlist.key, %5D))%0A        self.assertIsRedirect(resp)%0A        self.assertEqual(WishList.objects.count(), 0)%0A        self.assertEqual(self.product.wishlists_lines.count(), 0)%0A%0A%0A%0A%0A%0A%0A%0A%0A

Add tests for wishlists