candlepin/candlepin — pull request #370 by jmrodri (2013-09-05 15:40:28+00:00)
Title: 1004780: truncate result string to fit in db

The JobStatus.update() method was not calling the setResult method, which
means the result would be set to whatever string the JobExecutionContext
had, even one longer than 255 characters. This issue was fixed some time
ago in the setResult() method, where we truncate the text.

The JobStatus.update() method was changed to call setResult() to avoid
this data issue. While there, update() now calls setState() as well.
The other members do not have setters or data transformations, so no
setters were called for those.

Added a test in the JobCuratorTest because this error only surfaced when
using an actual database.