Added unit tests and tested on Mono