added a lot of unit testing
unit testing