Commit dd99ef29 authored by R E's avatar R E

Add unit tests

parent ef5744d8
from django.test import TestCase from django.test import TestCase
class HomePageTest(TestCase):
def test_home_page_returns_correct_html(self):
response = self.client.get('/')
self.assertTemplateUsed(response, 'home.html')
class CloudViewTest(TestCase):
def test_cloud_page_returns_correct_html(self):
response = self.client.get('/hero/cloud')
self.assertTemplateUsed(response, 'detail_cloud.html')
class JesterViewTest(TestCase):
def test_jester_page_returns_correct_html(self):
response = self.client.get('/hero/jester')
self.assertTemplateUsed(response, 'detail_jester.html')
class SunfloweyViewTest(TestCase):
def test_sunflowey_page_returns_correct_html(self):
response = self.client.get('/hero/sunflowey')
self.assertTemplateUsed(response, 'detail_sunflowey.html')
\ No newline at end of file
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