pytest
The most popular Python test framework: plain assert statements, fixtures and plugins.
Easy
def test_divider():
assert divider(5, 1000, 1000) == 2.5
Run pytest -q. Fixtures provide setup; @pytest.mark.parametrize runs one test over many inputs.
Spotted a mistake or want to add detail? Suggest an improvement — Content Contributors' edits are reviewed by editors before they go live.
Discussion (0)
Sign in or join free to ask questions and discuss this topic.