https://github.com/hub-ry/pytest
I am working on a project where I need to learn PyTest.
Notes From FreeCodeCamp
What is Pytest:
- Testing framework
- Auto-discover of test? What
- Pick up test based on the way that we name them (test_nameoffunction)
- Rich assertion introspection? What
- When a test fails we get a report
- Support parameterized and fixture based testing
- Easily run a test multiple times with different parameters
Why use Pytest:
- Simplified syntax (asserts)
- Clear reports
- Powerful fixture system
- Flexible and powerful (setup and teardown )
- Compatibility (compatible knowledge with different testing platforms)
- Extensibility
pip(3) install pytest
assert() If it is true then it continues, if it is false it completely stops the program (assertion error)