Add unit test and travis support
Merge pull request #7 from yurenju/travis

Add unit test and travis support