def test_write_attr(self):
    key = Text.create_from('Hello')
    value = Text.create_from('Friend')
    writer = _ReconWriter()
    actual = writer._write_attr(key, value)
    self.assertIsInstance(actual, _OutputMessage)
    self.assertEqual(14, actual._size)
    self.assertEqual('@Hello(Friend)', actual._value)
    self.assertEqual(')', actual._last_char)
def test_write_attr(self):
    key = Text.create_from('Hello')
    value = Text.create_from('Friend')
    writer = _ReconWriter()
    actual = writer._write_attr(key, value)
    self.assertIsInstance(actual, _OutputMessage)
    self.assertEqual(14, actual._size)
    self.assertEqual('@Hello(Friend)', actual._value)
    self.assertEqual(')', actual._last_char)