fix the typo in the path
add unit tests and fix minor bugs