Create gem with test suite

- [ ] make the code to installable gem
- [ ] have a test suite against code, need refactoring code