Make tests part of the package to test with OFP
Fix some tests for more general purpose use