Fix entity definition as per BZ 1122261

Also: improve the output of error messages in test case `LongMessageTestCase`.
You can specify multiple string types. Any sequence type, such as a list or tuple, can be provided.