def test_cropped_when_too_long_even_without_description(self):
        profileid = 'my.package:default'

        note = TransactionNote()
        for destination in range(1, (65533 / len(profileid)) + 2):
            note.add_upgrade(profileid, (str(destination),), '')

        note = transaction.get().description

        expected_start = 'my.package:default -> 1\n'
        self.assertTrue(
            note.startswith(expected_start),
            ('Expected transaction note to start with "%s",'
             ' but it started with "%s"') % (
                expected_start, note[:50]))

        self.assertTrue(
            note.endswith('...'),
            'Expected transaction note to be cropped, ending with "..." '
            'but it ends with "%s"' % note[-30:])