Commit c9528cc6 authored by Xavier Calabia's avatar Xavier Calabia

completed the functional test

parent ad84b54e
......@@ -19,17 +19,20 @@ class NewVisitorTest(unittest.TestCase):
# She sees a list containing three heroes with their corresponding
# names, health points, and damage
self.browser.find_element_by_tag_name('ul')
# When she selects one of the heroes, she is sent to another page
# containing more information about the hero (additional stats, lore, image).
element = self.browser.find_element_by_link_text('Cloud')
element.click()
# She spots the page title and header mentions the name of the hero she selected.
self.assertIn('[placeholder]', self.browser.title)
self.assertIn('Detail - Cloud', self.browser.title)
# While she is in a specific hero's page, she sees a button labeled "Back to Heroes List".
# She clicks this and she is redirected back to the wiki's homepage.
self.fail('Finish the test!')
element = self.browser.find_element_by_tag_name('button')
self.assertIn('Back to Heroes List', element.text)
if __name__ == '__main__':
unittest.main(warnings='ignore')
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