Fixed minor issues

* Added tests for triggering all BON_ERR_* when reading
* Fixed some issues with triggering the right error at the right time