Fixed config directory
Update examples
Add optional arguments. Add test