Add: ignore vim files
Mod: improved tests

factorized code
changed some naming