Made a start on unit tests