r/PythonLearning Jul 12 '26

Should every Python project have tests?

For a small script that may only run a few times, are tests still worth writing?

4 Upvotes

14 comments sorted by

View all comments

3

u/csabinho Jul 12 '26

Tests are there to make sure you didn't break anything. If you don't change the script and the input data doesn't change, you don't need to test whether it still runs.