GMLC-TDC / pyhelics

CFFI Python interface for HELICS
https://python.helics.org
BSD 3-Clause "New" or "Revised" License
3 stars 8 forks source link

Remove repr in tests #96

Closed josephmckinsey closed 6 months ago

josephmckinsey commented 7 months ago

Replaces all repr testing with two functions:

I'm not 100% with using a helper function since dictionaries are harder to automatically refactor, but using a dictionary allows the possibility of reuse and can be more concise.

I also couldn't help myself and cleaned up a few things in the tests which were a bit strange.

I replaced many of the sys.path.append commands with .utils. This may cause a problem if you have not installed helics using pip install and are still trying to run tests from somewhere other than the root directory. Considering how annoying sys.path.append for any automatic tooling, I consider this specific use case somewhat irrelevant.