added unit tests

I have added some tests with the default value of 0.
I hope this fixes #111 and fixes #24