Added tests.
Updated readme.