Our task manager does stuff now, though in a primitive form. I ended the last installment by reflecting on the tons and tons of stuff that this software does not do and that we would like it to do.
Testing software is an essential part of improving it. (Here are some other things I think about software testing, if you're curious.) And the best way to test almost all software is with other software.
So, even at this very early stage, we must confront the question of incorporating other software into our software. There is a lot to know here: again, you'll hear people say that knowing a lot about the subject is a hard prerequisite for doing anything useful as a programmer. This claim is refuted by the observation that only a small minority of working programmers have any kind of expert knowledge of how software packaging, distribution, etc. work.
I therefore recommend you absorb these facts, at any level of depth you find appropriate right now. As always, I state them briefly not because they are easy to understand but because I'm relying on excellent treatments elsewhere. 1. You can use other software--especially, other Python software--in the software you write in Python. 1. A common convention for documenting what software you're incorporating is by listing the software you plan to use in a file called requirements.txt. 1. Software is distributed in units called "packages." 1. Python software packages are commonly installed with a tool called "pip".
pip
or pip3
.requirements.txt
file in the veery/
directory.pytest==7.1.2
, in that file.pip install -r requirements.txt
.As you might have guessed, we will be using Pytest to test our code. Among full-featured test frameworks for Python, it is by far the friendliest and most intuitive.
Good luck! Here's the current commit in the veery/ repository.
Next post: Python task manager from scratch, part 9: First tests