Adding tests. Also working on cleaning up the API