Runs tests now sucessfully. Bit of cleanup still to do