Added lots more test coverage