Create testsuite for the project
As the project is maturing, it will eventually be necessary to write more and more tests. The purpose of unit tests is to assure that every part of the software works as it is designed. Writing unit tests helps you to make sure that you have not implemented buggy code, and assures that you will get notified if you change code that breaks a test.
Unit tests should fail if either you have introduced buggy code, in which case you should rewrite your code, or if there have been changes in the code requirements, i.e. the code is now supposed to do something different compared to what it did before. In the latter case the tests should be rewritten to reflect the new code requirements.
It is pretty clear that writing tests right at the start is hard because we are still changing the API all the time.
If you haven't written unit tests before, it isinstructive to look up some short guides into unit testing in general(e.g. https://esj.com/Articles/2012/09/24/Better-Unit-Testing.aspx?Page=1 or https://fullstack.industries/blog/five-principles-of-unit-testing/).
Unit tests should ideally test the entire functionality of the programme. However, it may be hard to cover everything, especially within the scientific context some things just end up being hard to test. If you want to have a look at what simple tests should look like in our case, then you can have a look at parameter_tests.py
, which currently runs 16 different tests on the Parameter class.