Commit b0ffdb16 authored by Alec Wang's avatar Alec Wang

added tests for recipes pages

parent dca43cf1
......@@ -45,3 +45,25 @@ class OrdersPagesTests(TestCase):
response = self.client.get('/orders_detail/')
self.assertContains(response, "Orders - Detail", html=True)
self.assertTemplateUsed(response, 'orders_detail.html')
class RecipesPagesTests(TestCase):
def test_recipes_list_page(self):
response = self.client.get('/recipes_list/')
self.assertContains(response, "Recipes - List", html=True)
self.assertTemplateUsed(response, 'recipes_list.html')
def test_recipes_create_page(self):
response = self.client.get('/recipes_create/')
self.assertContains(response, "Recipes - Create", html=True)
self.assertTemplateUsed(response, 'recipes_create_form.html')
def test_recipes_update_page(self):
response = self.client.get('/recipes_update/')
self.assertContains(response, "Recipes - Update", html=True)
self.assertTemplateUsed(response, 'recipes_update_form.html')
def test_recipes_detail_page(self):
response = self.client.get('/recipes_detail/')
self.assertContains(response, "Recipes - Detail", html=True)
self.assertTemplateUsed(response, 'recipes_detail.html')
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment