Some work done on the tests and fixed a few issues in the packages.