Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
T
thegoodplace
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
Santino Campos
thegoodplace
Commits
2f161a2b
Commit
2f161a2b
authored
Mar 17, 2020
by
Santino Campos
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Write functional test for website
parent
abc9c7b9
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
12 additions
and
3 deletions
+12
-3
functional_test.py
functional_test.py
+12
-3
No files found.
functional_test.py
View file @
2f161a2b
...
...
@@ -15,45 +15,54 @@ class NewOrderToCheckTest(unittest.TestCase):
#Thibault first enters a new order into the website
#He goes to the order creation form of the website
#Test content of orders_create_form
self
.
assertIn
(
'<h1> Orders - Create </h1>'
,
self
.
browser
.
page_source
)
#He then goes to the list of all orders in the website to check if his inputted order is still there
#Test content of orders_list
self
.
assertIn
(
'<h1> Orders - List </h1>'
,
self
.
browser
.
page_source
)
#He then go to the page of the specific order he just inputted
#Test content of orders_detail
self
.
assertIn
(
'<h1> Orders - Detail </h1>'
,
self
.
browser
.
page_source
)
#He then notices that the order is lacking a specific customisation, so he updates the order information
#Test content of orders_update_form
self
.
assertIn
(
'<h1> Orders - Update </h1>'
,
self
.
browser
.
page_source
)
#Thibault then enters the new recipe into the website
#He goes to the recipe creation form of the website
#Test content of recipes_create_form
self
.
assertIn
(
'<h1> Recipes - Create </h1>'
,
self
.
browser
.
page_source
)
#He then goes to the list of all recipes in the website to check if his inputted recipe is still there
#Test content of recipes_list
self
.
assertIn
(
'<h1> Recipes - List </h1>'
,
self
.
browser
.
page_source
)
#He then go to the page of the specific recipe he just inputted
#Test content of recipes_detail
self
.
assertIn
(
'<h1> Recipes - Detail </h1>'
,
self
.
browser
.
page_source
)
#He then notices that the recipe is lacking an ingredient in its information, so he updates the recipe information
#Test content of recipes_update_form
self
.
assertIn
(
'<h1> Recipes - Update </h1>'
,
self
.
browser
.
page_source
)
#Thibault then enters the new ingredient into the website database
#He goes to the ingredient creation form of the website
#Test content of ingedients_create_form
self
.
assertIn
(
'<h1> Ingredients - Create </h1>'
,
self
.
browser
.
page_source
)
#He then goes to the list of all ingredientss in the website to check if his inputted ingredient is still there
#Test content of ingredients_list
self
.
assertIn
(
'<h1> Ingredients - List </h1>'
,
self
.
browser
.
page_source
)
#He then go to the page of the specific ingredient he just inputted
#Test content of ingredients_detail
self
.
assertIn
(
'<h1> Ingredients - Detail </h1>'
,
self
.
browser
.
page_source
)
#He then notices that the ingredien is labelled as having 5 units on hand, whereas the establishement never ordered this recipe before, he then updates its on-hand count to zero
#Test content of ingredients_update_form
self
.
assertIn
(
'<h1> Ingredients - Update </h1>'
,
self
.
browser
.
page_source
)
#He then closes the website
self
.
fail
(
'Finish the test!'
)
if
__name__
==
'__main__'
:
...
...
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