[#50] Update tests and further refactoring
[#50] Extract raw representation to package