re-structure python code and add unittest
add to gitignore