Programming Study日本語

Disclosure: We earn a commission from Udemy when you buy a course through links on this page.

pytest Complete Guide|Python Unit Testing with 50 Exercises

pytest Complete Guide|Python Unit Testing with 50 Exercises

Udemy · English

About this course

Language
English
Category
Provider
Udemy
Data updated

This is a hands-on pytest course that lifts your Python code from "it probably works" to "it works, and the tests prove it." It is designed so that people with zero testing experience can move forward one step at a time, starting from their very first `assert`.The heart of this course is 50 hands-on exercises - you will not just watch. Every lesson follows the same rhythm: a walkthrough video, an exercise you solve yourself, and a review video covering the model answer. Repeating that loop 50 times, writing real code and turning tests green, is how knowledge turns into something your hands remember. Upload the exercise ZIP to Google Cloud Shell and run the included setup script. No local Python installation is required. You need a Google account; free quotas are 50 hours per week and 5GB of storage. Accounts under 18 or with unknown age cannot use Cloud Shell. A local Python alternative is included. When videos show CodeSandbox, follow the updated startup lecture instead. Grading requires no API keys or paid Cloud resources. The content comes in two parts. Part 1 builds the core: how pytest collects tests automatically, the plain `assert` statement, comparing floats with approx, verifying exceptions with raises, data-driven testing with parametrize, sharing setup through fixtures and conftest, markers and skips, and measuring coverage. Part 2 covers what you meet at work: monkeypatch, the standard mock library and pytest-mock, verifying loggers and standard output, file I/O and SQLite, testing FastAPI APIs, async tests with httpx, snapshot testing, and capstone exercises that keep TDD and CI in mind. Go from "how am I even supposed to write a test?" to "I can put meaningful tests on my own code with confidence." Let's make testing your ally and become an engineer who writes code that does not break.

Courses in the same category