Thanks background from vecteezy

Getting Started TDD in 30 Seconds with Python

sudo pip install pipenv
mkdir my-tdd
cd my-tdd
pipenv shell
pipenv install pytest --dev
# in lib.pydef hello():
return "hello"
# in lib_test.py or test_lib.pyimport lib
def test_hello():
assert lib.hello() == "hello"
pytest
lib.py
lib_test.py
Pipfile
Pipfile.lock

Extra!

pipenv install pytest-watch
ptw

Software Engineer, using ASP.NET Core, React, TypeScript. Blog at thadaw.com

Software Engineer, using ASP.NET Core, React, TypeScript. Blog at thadaw.com