Added tests and updated README.md