Add tests for result conversion after errors