Added more tests and http handlers