Further work on unit tests