Adding a large test based on real-world data, including tests for #35

The data contributed by @trohovsky. This test makes sure that every
message is only processed once, exception messages are correctly packed
etc.

During writing of this test, some shortcomings of the APIs have been
identified and thus those APIs have been improved.