Bug fixes and started working on test and added travis