Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
F
Francia - Midterm Project
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Alex Bernard Francia
Francia - Midterm Project
Commits
99839ae3
Commit
99839ae3
authored
Mar 19, 2020
by
Alex Bernard Francia
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Home page unit test succesful.
parent
8dff3fa2
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
3 additions
and
2 deletions
+3
-2
tests.py
froyo/tests.py
+2
-1
urls.py
froyo/urls.py
+1
-1
No files found.
froyo/tests.py
View file @
99839ae3
from
django.urls
import
resolve
from
django.test
import
TestCase
from
.views
import
go_to_home_page
# Create your tests here.
class
HomePageTest
(
TestCase
):
def
test_root_url_resolves_to_home_page_view
(
self
):
found
=
resolve
(
'/'
)
self
.
assertEqual
(
found
.
func
,
home_page
)
\ No newline at end of file
self
.
assertEqual
(
found
.
func
,
go_to_home_page
)
\ No newline at end of file
froyo/urls.py
View file @
99839ae3
...
...
@@ -18,7 +18,7 @@ from .views import go_to_recipes_update_form
urlpatterns
=
[
url
(
r'^$'
,
go_to_home_page
,
name
=
'homepage'
),
url
(
r'^$'
,
go_to_home_page
,
name
=
'home
_
page'
),
url
(
r'^ingredients/detail$'
,
go_to_ingredients_detail
,
name
=
'ingredients_detail'
),
url
(
r'^ingredients/list$'
,
go_to_ingredients_list
,
name
=
'ingredients_list'
),
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment