Integration test

Fix #55 
Fix #54 
Fix #53