Added tests and various other boilerplate stuffs