Cleanup trailing whitespace
Add more assert calls