Test your Django views and forms using Selenium

Offered By
Coursera Project Network
In this Guided Project, you will:

learn how to setup Selenium for Django testing

test the Django view for the presence of HTML components

test whether a hyperlink and a form submit button work

Clock2 hours
IntermediateIntermediate
CloudNo download needed
VideoSplit-screen video
Comment DotsEnglish
LaptopDesktop only

In this 2-hour long project-based course, you will learn how Selenium can be integrated with your Django project. Selenium is quite fun to learn and use: it can make your python program pretend it is an actual user browsing a website, so it is ideal for testing web application. You will use Selenium to test various aspects of a sample Django project. After understanding how the sample project works, your will write Selenium test functions to test the views of the project apps. In particular, you will learn how to test the presence of certain strings in a web page, the presence of form elements, whether a link successfully navigates to the right page, and whether a form is successfully submitted. Note: This course works best for learners who are based in the North America region. We’re currently working on providing the same experience in other regions.

Skills you will develop

Django developmentPython TestingUnit TestingSelenium testingDjango forms

Learn step-by-step

In a video that plays in a split-screen with your work area, your instructor will walk you through these steps:

  1. Understand the sample Django project and its apps

  2. Setup the project for Selenium testing

  3. Perform basic tests on the view

  4. Test the form elements and links

  5. Test the form submission

How Guided Projects work

Your workspace is a cloud desktop right in your browser, no download required

In a split-screen video, your instructor guides you step-by-step

Frequently asked questions

Frequently Asked Questions

More questions? Visit the Learner Help Center.