Address lint issues (fix #1)
Adding unit tests and fixing issue found (fix #12)