TEM-Gemini-Centre / mib2hspy

Tools for converting MIB files to HSPY
GNU General Public License v3.0
0 stars 0 forks source link

Unit tests and command line interface #2

Open magnunor opened 3 years ago

magnunor commented 3 years ago

Adding some simple unit tests would useful. The easy way of doing this is using some MIB-files with only zeros, these can be zipped to be only a couple of kilobytes. These can then be used for testing the conversion.

However, this would probably require the ability to run the code via the command line.

emichr commented 3 years ago

Good idea! I've been planning on adding unit tests, but I've been too busy (which in the end is the wrong way to save time and efficiency). Anyways, most of the functionality should be possible to run through the command line already, but there are key elements missing.

The cleanest way would probably be to restructure the code, as it is today the functionality is too tightly interwoven with the GUI (which is backwards). This will take some time - BUT - it will also provide the perfect opportunity to build the code from well-defined unit tests on the get-go.