Pytest Master Class Full Course
Pytest Master Class Full Course
Learn to master testing in Python with Pytest from Five Time O'Reilly Author and AWS ML Hero Noah Gift
Pytest is a testing framework for Python that allows you to write tests in a readable and concise way.
This close to three-hour course will teach you how to write tests in Python using Pytest as well as master CI/CD with Pytest.
Take your testing and DevOps skills to the next level with this full-course Pytest Master Class.
Topics Covered Include:
* 00:00 Introduction
* 03:38 What is DevOps?
* 05:32 Github CodeSpaces
* 09:45 Create Python Project Structure: Makefile, requirements.txt, test file and virtualenv
* 16:33 Importing code with IPython
* 17:32 Writing tests with Pytest
* 21:58 Using Pylint
* 23:56 Verifying Pylint bad syntax catch
* 25:41 Formatting code with Black
* 26:38 Pinning requirements to a specific version
* 30:00 Setup Github Actions
* 37:38 Matrix Testing multiple versions of a Python 3.6, 3.7, 3.8, 3.9 with Github Actions
* 50:00 Using AWS CloudShell
* 53:00 Using AWS Cloud9
* 54:07 Adding virtualenv to ~/.bashrc
* 57:24 Using AWS CodeBuild
* 01:17:01 Testing Google Colab Notebooks and Jupyter Notebooks with nbval and Pytest
* 01:29:39 Using pdb;pdb.set_trace() and ipdb;ipdb.set_trace()
* 01:35:53 Using pytest-cov
* 01:37:47 Using pytest with --pdb pdb debbuging during tests
* 01:38:12 Using pytest with --pdb --maxfailures 1 to stop after first failure
* 01:42:20 Using pytest to test a single test
* 01:49:25 Using Pytest with fixtures
* 01:56:23 Using Pytest setup_function and teardown_function to setup and teardown of tests
* 02:00:00 Using flask web framework
* 02:04:25 Testing flask web framework with pytest
* 02:10:46 Extending flask with a greedy coin change machine
* 02:21:27 Using click to create a command line interface
* 02:30:39 Using Pytest to test click command line interfaces
* 02:44:42 Matrix testing entire project with click, pytest, and nbval using Github Actions and multiple versions of Python 3.6, 3.7, 3.8, 3.9
Learning Objectives
This course covers the following learning objectives:
- Learn to master Pytest.
- Learn to setup CI/CD pipelines with Pytest, Pylint, Python Black Formatting, Github Actions and AWS CodeBuild.
- Learn to use Cloud-based development environments with Pytest like Githhub CodeSpaces, AWS Cloud9 and AWS CloudShell
- Learn to create local test environments with Pytest and Virtualenv
- Learn to use advanced functions like Pytest test selection, pdb (python debugger) and fixtures.
- Learn to build realistic problems including libraries, building command-line tools with Click and web frameworks with Flask.
Buy a copy of Testing in Python on Amazon: https://www.amazon.com/Testing-Python-Robust-Professionals/dp/B0857CFM17
Buy a copy of Python for DevOps on Amazon: https://www.amazon.com/Python-DevOps-Ruthlessly-Effective-Automation/dp/149205769X
Buy a copy of Practical MLOps: https://www.amazon.com/Python-DevOps-Ruthlessly-Effective-Automation/dp/149205769X If you enjoyed this video, here are additional resources to look at:
Coursera + Duke Specialization: Building Cloud Computing Solutions at Scale Specialization: https://www.coursera.org/specializations/building-cloud-computing-solutions-at-scale
O'Reilly Book: Practical MLOps: https://www.amazon.com/Practical-MLOps-Operationalizing-Machine-Learning/dp/1098103017
O'Reilly Book: Python for DevOps: https://www.amazon.com/gp/product/B082P97LDW/
Pragmatic AI: An Introduction to Cloud-based Machine Learning: https://www.amazon.com/gp/product/B07FB8F8QP/
Pragmatic AI Labs Book: Python Command-Line Tools: https://www.amazon.com/gp/product/B0855FSFYZ
Pragmatic AI Labs Book: Cloud Computing for Data Analysis : https://www.amazon.com/gp/product/B0992BN7W8
Pragmatic AI Book: Minimal Python: https://www.amazon.com/gp/product/B0855NSRR7
Pragmatic AI Book: Testing in Python: https://www.amazon.com/gp/product/B0855NSRR7
Subscribe to Pragmatic AI Labs YouTube Channel: https://www.youtube.com/channel/UCNDfiL0D1LUeKWAkRE1xO5Q
View content on noahgift.com: https://noahgift.com/
View content on Pragmatic AI Labs Website: https://paiml.com/
Other Videos By Pragmatic AI Labs
2021-11-21 | MLOps Live |
2021-11-21 | Pragmatic AI Labs Live Stream |
2021-11-21 | Learn AWS CloudShell |
2021-11-17 | Learn to use AWS Sagemaker |
2021-11-11 | AWS lambda python cloud9 and Boto3 one hour |
2021-11-11 | Python command line one hour |
2021-11-11 | Python functions one hour |
2021-11-11 | Python statements one hour |
2021-11-02 | MLOPs chronicles 11 2021 |
2021-10-26 | Hello world IAC with AWS CDK |
2021-10-26 | Pytest Master Class Full Course |
2021-10-23 | Ancient Full Stack Civilization |
2021-10-23 | MLOps containers with AWS and GCP |
2021-10-23 | Github actions vs AWS Codebuild |
2021-10-13 | Getting Started with Data Pipelines |
2021-10-09 | Python continuous integration for the commmand line |
2021-10-02 | Data Science for Infrastructure |
2021-09-27 | Bike Shedding |
2021-09-15 | Google cloud functions for the impatient |
2021-09-12 | Data Engineering with AWS Step Functions for the impatient |
2021-09-12 | Optimization With AWS Step Functions |