Add tests & fix layout