Provide close callback
Add force-exit flag
update test to work with latest pull request
update for version 0.5.1
update docs with new force-exit option