Fixed typos in views, test, and urls, added a line to fix 'template does not...

Fixed typos in views, test, and urls, added a line to fix 'template does not exist' error in settings
parent 2079bf36
from django.test import TestCase
from django.urls import resolve
from django.http import HttpRequest
from .views import IngredientsListView, IngredientsDetailView, IngredientsUpdateView, IngredientsCreateView, RecipesListView, RecipesDetailView, RecipesUpdateView, RecipesCreateView, OrdersListView, OrdersDetailView, OrdersUpdateView, OrdersCreateView
#ingredients model
......
from django.conf.urls import url
from .views import HomeTemplateView, CloudTemplateView, JesterTemplateView, SunfloweyTemplateView
urlpatterns = [
url(r'^$', HomeTemplateView.as_view(), name='home'),
url(r'^hero/cloud/$', CloudTemplateView.as_view(), name='detail_cloud'),
url(r'^hero/jester/$', JesterTemplateView.as_view(), name='detail_jester'),
url(r'^hero/sunflowey/$', SunfloweyTemplateView.as_view(), name='detail_sunflowey'),
]
from django.conf.urls import url
from .views import IngredientsListView, IngredientsDetailView, IngredientsUpdateView, IngredientsCreateView, RecipesListView, RecipesDetailView, RecipesUpdateView, RecipesCreateView, OrdersListView, OrdersDetailView, OrdersUpdateView, OrdersCreateView
urlpatterns = [
......
......@@ -15,7 +15,7 @@ class IngredientsUpdateView(TemplateView):
template_name = 'ingredients_update_form.html'
class IngredientsUpdateView(TemplateView):
class IngredientsCreateView(TemplateView):
template_name = 'ingredients_create_form.html'
......
......@@ -6,7 +6,7 @@ from selenium import webdriver
class NewVisitorTest(unittest.TestCase):
def setUp(self):
self.browser = webdriver.Firefox()
self.browser = webdriver.Chrome()
def tearDown(self):
self.browser.quit()
......@@ -88,6 +88,8 @@ class NewVisitorTest(unittest.TestCase):
#self.assertIn('', self.browser.find_element_by_id('new_size').text)
#self.assertIn('', self.browser.find_element_by_id('new_base_recipe').text)
#self.assertIn('',self.browser.find_element_by_id('new_customization').text)
self.fail('Finish the test!')
if __name__ == '__main__':
......
......@@ -55,7 +55,7 @@ ROOT_URLCONF = 'thegoodplace.urls'
TEMPLATES = [
{
'BACKEND': 'django.template.backends.django.DjangoTemplates',
'DIRS': [],
'DIRS': [os.path.join(BASE_DIR, 'templates'), os.path.join(BASE_DIR, 'froyo', 'templates')],
'APP_DIRS': True,
'OPTIONS': {
'context_processors': [
......
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