Real World Python Test Automation with Pytest Django app

Learn Pytest by building a full Django application with a Continuous Integration system, software testing best practices
Real World Python Test Automation with Pytest Django app
File Size :
4.79 GB
Total length :
7h 11m



Eden Marco


Last update

Last updated 9/2022



Real World Python Test Automation with Pytest Django app

What you’ll learn

Learn the ins and outs of Pytest
Build a real world Django web server
Build a continuous integration system
Testing Best Practices
Build high-performing, reliable automated test suites
Allure Reporting
Slack messaging
Unit, Integration, E2E, performance tests
Mocking and Patching

Real World Python Test Automation with Pytest Django app


Advanced knowledge of python – This is NOT a beginner course


This is a MUST course for anyone who cares about testing.I teach the ins and outs of pytest while building a real-world Django application (including a continuous integration system in bitbucket).In this course, we will build a very simple Django server, I will teach just enough Django so that we will be able to build the application and then focus on testing it.We will together test the application from all angels – Unit tests, integration tests, API tests, end-to-end tests , and performance tests with (a total of over 40 tests)You will end up with a complete CI system that integrates bitbucket cloud pipelines, slack messaging, and allure reporting.Every time we will make a push, the CI system will run our tests and will notify us if the build passed/failed.In this course, we go in-depth, and we will even implement together (from scratch) some of pytest’s features so that we will know what happens under the hood when pytest is running our tests.This is not an entry-level course; basic knowledge of python is needed You will learn:Pytest features (in-depth)FixturesMarkersParametrizeSkip, xfailPytest.iniPytest-djangoPytest-covpytest-xdistunittest library, mocksRequests libraryDjango (just enough to build a web server)Rest APIModels, MigrationsViewsSerializersSQLite3 DBEmail backendsContinuous Integration (in-depth)Bitbucket pipelinesBitbucket environment variablesParallel stepsDockerSlack messaging integrationAllure ReportingTesting (In-depth)Unit testsMocking. Patching, StubsIntegration testsPerformance testsTesting environmentsPython best practiceVirtual environments: pipenvPipfileType hintingBlack formatter.env FileRecreating react our projects UI (No prior knowledge is needed


Section 1: Introduction: Course topics, learning tips

Lecture 1 Course Topics

Lecture 2 About the instructor (Corona Virus Edition)

Lecture 3 How get the best of Udemy

Lecture 4 Short explanation of course sections

Lecture 5 Course Goals- What Is In It For You

Lecture 6 How I suggest watching the course – Watch this Before moving to the next section

Lecture 7 Course Telegram Channel

Section 2: Pytest Quick Start Tutorial

Lecture 8 Pytest Quick Overview

Lecture 9 The GIST of pytest in 20 minuets – Markers

Lecture 10 The GIST of pytest in 20 minuets – Fixtures, Parametrize

Section 3: Unit tests VS Integration tests

Lecture 11 Unit tests VS Integration tests

Section 4: Setting Up Your Development Environment

Lecture 12 Creating a bitbucket project

Lecture 13 Installing pipenv and required packages

Section 5: Creating and testing our awesome Django project

Lecture 14 What are we going to build

Lecture 15 Django project setup

Lecture 16 Creating our Django Models

Lecture 17 Creating our REST API

Lecture 18 Manually testing our project’s features

Section 6: Pytest automatic testing for our Django application

Lecture 19 Writing our first pytests

Lecture 20 API Test classes (unittest style)

Lecture 21 Pytest skip and xfail markers

Lecture 22 Pytest tests that assert Exceptions

Lecture 23 Pytest tests that assert Logs

Lecture 24 Pytest test runner

Lecture 25 Testing Django Applications

Lecture 26 Refactoring our tests to pytest native

Lecture 27 Summery: Pytest VS unittest

Section 7: Continuous Integration

Lecture 28 Intro to Continuous Integration

Lecture 29 Hands on CI- creating bitbucket pipelines to run our tests

Lecture 30 Hands on CI- Bitbucket environment variables

Section 8: Django emailing service

Lecture 31 Adding an email sending service

Lecture 32 Testing our email service

Lecture 33 Refactoring our Tests to Pytest

Section 9: Exploring Pytest with Fibonacci

Lecture 34 Intro to fibonacci tests

Lecture 35 Pytest Parametrize

Lecture 36 Implementing from scratch Pytests’s parametrize feature

Lecture 37 Caching

Lecture 38 Running CI steps in paralell

Lecture 39 Pytest fixture- Time tracking

Lecture 40 Using dynamic programming to solve fiobnacci

Section 10: Performance Testing

Lecture 41 Implementing a pytest performance validator

Lecture 42 Why not to use pytest-timeout

Section 11: Pytest Assert Magic

Lecture 43 Pytest Assert Magic

Section 12: Endpoint Assignment

Lecture 44 Assignment

Section 13: Pytest-xdist

Lecture 45 Running our tests on multiple threads with pytest-xdist

Section 14: Slack CI Integration

Lecture 46 Setting a slack notification when bitbucket CI pipeline fails/passes

Section 15: Advanced Pytest Fixtures

Lecture 47 Pytest Fixtures Theory

Lecture 48 Fixtures with arguments

Lecture 49 Executing parametrized fixtures

Section 16: files and .env file

Lecture 50

Lecture 51 .env file (auto reloading environment variables)

Section 17: Server Agnostic API Testing (requests library)

Lecture 52 Server Agnostic API Testing with requests library (part 1)

Lecture 53 Server Agnostic API Testing with requests library (part 2)

Lecture 54 Mocking Requests to Isolate 3rd party dependencies in test functions (Theory)

Lecture 55 Mocking Requests to Isolate 3rd party dependencies in test functions (Hands On)

Section 18: Allure Report Tool

Lecture 56 What is Allure reporting

Lecture 57 End To end Allure Integration – Test Report Webserver

Section 19: Cool Plugins For pytest

Lecture 58 Pytest-sugar

Section 20: Mocking in Python

Lecture 59 Python Mocking Theory

Lecture 60 How to Patch Like a PRO

Lecture 61 Patch is Hijacking Target’s memory address

Section 21: Testing Concepts

Lecture 62 Testing In Production

Section 22: Bonus

Lecture 63 Build the react frontend application

Section 23: Troubleshooting Section

Lecture 64 What is the troubleshooting section for?

Lecture 65 Configure Pycharm Default Test Runner to Pytest and set global Pytets Env Vars

Lecture 66 Frequently Asked Import Errors (In depth explanation + resolution)

Lecture 67 Frequently Asked INSTALLED_APPS RuntimeError (explanation + resolution)

Lecture 68 Clone The Ready to go Django Project (If you are just interested in pytest)

Section 24: Congratulations – Software Developer Certificate

Lecture 69 Congratulations – Software Developer Certificate

Lecture 70 What’s next?

Developers who are interested in writing quality tests for their applications,Python Developers curious about Pytest,Anyone who wants to build or improve an automated testing framework,QA Engineers who wants to learn about pytest

Course Information:

Udemy | English | 7h 11m | 4.79 GB
Created by: Eden Marco

You Can See More Courses in the IT & Software >> Greetings from

New Courses

Scroll to Top