Python Testing with Green
What you'll learn
- Improve code quality.
- Refactor code without fear.
- Have a better coding experience.
- Be able to better help others.
Requirements
- Familiarity with Python
Description
Ever wonder why some projects seem able to make huge changes and still ship promptly, while others collapse under the weight of their own code? Testing is the difference! Effective tests enable you to add features quickly, refactor your code without fear, and ship new releases without big new bugs.
Make Your Project Successful by Writing Meaningful Tests
- Layout your test packages and modules correctly
- Organize your tests effectively
- Learn the tools in the unittest module
- Run your test with Green, a powerful new test runner
- Write meaningful tests that enable quick refactoring
- Learn the difference between unit and integration tests
- Use advanced tips and tricks to get the most out of your tests.
Python Testing with Green
Tests are just a way of writing code that uses your project and makes sure that it really does what you think it does! We'll learn the best way to write tests and some common problems and pitfalls that you should avoid.
This course is designed as a practical reference for Python programmers who have real code that they would like to start testing, or test more effectively. I provide real runnable examples that you can type in yourself or download from the resources section.
The beginner section requires zero prior testing knowledge. I teach the fundamental basics of testing Python code including how to run your tests the "traditional" way as well as with the high-performance Green test runner. After completing this section, you will be able to write tests and run them.
The intermediate section teaches you how to write meaningful tests, and covers every aspect of the Python "unittest" module that you will use in daily life. Upon completing this section, you will know more than most Python programmers about how to test your code.
In the advanced section I go over how to mock unit tests, integration testing, advanced usage of the Green test runner, and some tips and tricks for getting the most out of your testing. Only an elite few gain this level of knowledge on their own. After completing this section, you will be a master of Python testing.
Who this course is for:
- Likes pretty colors
- Believes that testing can improve their code
- Prefers interfaces carefully crafted for usability AND aesthetics
- Believes fast tests are better than slow tests
- Understands that a good continuous integration solution improves quality of life.
Instructor
Nathan Stocks has been a software developer for over 20 years. He fell in love with Rust in 2016 and began teaching it the following year. He experiments with Indie Game development in both Rust and more traditional game engines. He has used Python professionally for most of his career, and even wrote his own test runner called Green.
Nathan loves teaching Rust when he gets the chance, especially in person at conferences and corporate boot camps.
If Nathan had to pick his favorites, they would be: Rust, Python, PostgreSQL, Linux (server), macOS (desktop), vim and emacs, and whichever IDE has the best Rust support at the moment.
Nathan loves to spend time with his wife and kids, play frisbee, eat food, and play games. His ambition is to one day run his own software company where he can spend his days fanatically polishing a product that his customers love.